Installation overview
Pick your setup, then check the requirements below.
| Your project | Guide |
|---|---|
React Native CLI app (npx @react-native-community/cli init) | React Native CLI |
Expo app (managed or with ios/ and android/ folders) | Expo |
Web, through react-native-web or Expo web | Web |
Requirements
| Requirement | Minimum | Notes |
|---|---|---|
| React | 18.2 | Uses useSyncExternalStore and useId |
| React Native | 0.73 | Peer dependency. Developed against 0.76 |
| iOS deployment target | 15.0 | UISheetPresentationController. Custom snap heights need iOS 16 |
Android minSdkVersion | 24 (Android 7.0) | Declared by the library |
Android compileSdkVersion | 34 | Used to build the library module |
| Java / Kotlin | Java 17 | The library module is written in Kotlin |
| Expo SDK | 51 | Development builds only, not Expo Go |
react-native-web | 0.19 | Only for web |
react-dom | 18.2 | Only for web |
| Node.js | 18 | For the React Native toolchain |
Full matrix, including what has been tested: Version compatibility.
Project checklist
Before you use the library, make sure your project has these:
- [ ] The package installed:
npm install react-native-universal-sheet. - [ ] iOS pods installed:
cd ios && pod installafter every install or upgrade. - [ ] iOS deployment target of 15.0 or later in your
Podfile(platform :ios, '15.0'). Expo apps get this from the config plugin. - [ ] Android
minSdkVersionof 24 or later inandroid/build.gradle. React Native 0.73+ already uses 23 or 24; raise it if yours is lower. - [ ] A rebuilt native app. The library contains native code, so a Metro reload is not enough after installing. Run
npx react-native run-ios/run-androidornpx expo run:ios/run:android. - [ ]
<NativeSheetProvider>once at the root, above your navigator. - [ ] For web only:
react-domandreact-native-webinstalled, and your bundler resolving.web.tsxfiles.
You do not need:
react-native-reanimatedorreact-native-gesture-handler. Animation and gestures are native.- A Material theme on Android. The default React Native
AppCompattheme works. - Any manual linking. Autolinking handles iOS and Android.
Install
sh
npm install react-native-universal-sheetsh
yarn add react-native-universal-sheetsh
pnpm add react-native-universal-sheetsh
npx expo install react-native-universal-sheetThen continue with the guide for your setup.