react-native-cq-keyboard-listener

Acquire keyboard height.

Usage no npm install needed!

<script type="module">
  import reactNativeCqKeyboardListener from 'https://cdn.skypack.dev/react-native-cq-keyboard-listener';
</script>

README

Npm Install

$ npm install --save react-native-cq-keyboard-listener

Automatically Link

$ react-native link react-native-cq-keyboard-listener

Manual Link

Update Gradle Settings
Add libKeyboardListener.a in TARGETS -> Buidl Phases -> Link Vinary With Libbraries  

Use

import React, { Component } from 'react';
import {
    Platform,
    StyleSheet,
    Text,
    View
} from 'react-native';

import KeyboardListenerView from 'react-native-cq-keyboard-listener'

export default class App extends Component {
render() {
    return (
        <View style={styles.container}>

        // Add this component to the outermost layer of the current page.
        <KeyboardListenerView onChange={(height)=>console.log(height)}/>
        </View>
        );
    }
}