A library to obtain Android Navigation Bar height
npm install react-native-android-navbar-heightA library to obtain Android Navigation Bar height
Add the following line into your package.json:
``sh`
yarn add react-native-android-navbar-height
or
`sh`
npm i --save react-native-android-navbar-height
`js
import { getNavigationBarHeight, getNavigationBarHeightAsync } from "react-native-android-navbar-height";
// ...
// sync method, blocking JS-thread
const navigationBarHeight = getNavigationBarHeight();
// async method, non-blocking JS-thread
(async () => {
const navigationBarHeight = await getNavigationBarHeightAsync();
})();
``
See example for more info https://github.com/NikitaDudin/react-native-android-navbar-height/blob/main/example/src/App.tsx
See the contributing guide to learn how to contribute to the repository and the development workflow.
Got troubles with integration? Create an issue at Issues page.
MIT
---
Made with create-react-native-library