I'm working on a project using React Native 0.72.4 (using the default Paper architecture) and I'm encountering build errors on Android related to react-native-screens. The error output (truncated) is as follows: I cant remove the navigation libraries they are mandatory.
e: .../node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/RNScreensPackage.kt:3:27 Unresolved reference: BaseReactPackage
e: .../RNScreensPackage.kt:19:26 Unresolved reference: BaseReactPackage
e: .../RNScreensPackage.kt:24:5 'createViewManagers' overrides nothing
e: .../RNScreensPackage.kt:51:5 'getModule' overrides nothing
e: .../RNScreensPackage.kt:61:5 'getReactModuleInfoProvider' overrides nothing
Environment
- React Native: 0.72.4
- react-native-screens: Installed version is 4.6.0
- react-native-gesture-handler: Installed version is 2.16.0
- Android: Using standard Android project settings with auto-linking enabled
**Here is view of my package.json dependancies **
"dependencies": {
"@react-native-community/cli-platform-android": "^11.4.1",
"@react-navigation/bottom-tabs": "^7.2.0",
"@react-navigation/drawer": "^7.1.1",
"@react-navigation/native": "^7.0.14",
"@react-navigation/stack": "^7.1.1",
"axios": "^1.7.9",
"react": "18.2.0",
"react-native": "^0.72.4",
"react-native-gesture-handler": "^2.16.0",
"react-native-reanimated": "^3.15.1",
"react-native-safe-area-context": "^4.14.1",
"react-native-screens": "^4.6.0",
"react-native-vector-icons": "^10.2.0",
"rn-fetch-blob": "^0.12.0"
}
Question
- Could someone please advise on a set of version recommendations (or version matrix) that works reliably together? Specifically
- Is there a specific version of react‑native‑screens (for example, a version such as 4.4.0) that is known to work with React Native 0.72.4 (Paper) and React Navigation without triggering errors like the BaseReactPackage issue?
- Are the current versions of react‑native‑gesture‑handler (2.16.0) and the other navigation libraries (@react-navigation/bottom-tabs, etc.) compatible with that version of react‑native‑screens?
- Any additional configuration changes (e.g., in gradle or native code) that may be required?