# @react-native-menu/menu ![Supports Android, iOS][support-badge]![Github Action Badge][gha-badge] ![npm][npm-badge] Android PopupMenu and iOS14+ UIMenu components for react-native. Falls back to ActionSheet for versions below iOS14. | Android | iOS 14+ | iOS 13 | |--------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------| | | | | ## Installation via npm: ```sh npm install @react-native-menu/menu ``` via yarn: ```sh yarn add @react-native-menu/menu ``` ### Installing on iOS with React Native 0.63 and above There is an issue(https://github.com/facebook/react-native/issues/29246) causing projects with this module to fail on build on React Native 0.63 and above. This issue may be fixed in future versions of react native. As a work around, look for lines in `[YourPrject].xcodeproj` under `LIBRARY_SEARCH_PATHS` with `"\"$(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)\"",` and change `swift-5.0` to `swift-5.3`. ## Linking The package is [automatically linked](https://github.com/react-native-community/cli/blob/master/docs/autolinking.md) when building the app. All you need to do is: ```sh npx pod-install ``` ## Usage ```jsx import { MenuView, MenuComponentRef } from '@react-native-menu/menu'; // ... const App = () => { const menuRef = useRef(null); return (