I'm creating a React Native app. When I run the application in Expo Go
, everything builds perfectly, and everything is working fine. However, when I try to build the application
with react-native-cli
, I encounter an issue. Now, when I try to open the application, I'm getting this Rendering Error: Invariant Violation: requireNativeComponent: "RNCSafeAreaProvider" was not found in the UIManager.
Below is a list of my dependencies from the package.json file
ERROR: screenshot
{
"name": "Mario",
"version": "1.0.0",
"main": "node_modules/expo/AppEntry.js",
"scripts": {
"start": "expo start",
"android": "expo start --android",
"ios": "expo start --ios",
"web": "expo start --web"
},
"dependencies": {
"@dietime/react-native-date-picker": "^1.2.1",
"@gorhom/bottom-sheet": "^4.4.7",
"@react-native-async-storage/async-storage": "1.18.2",
"@react-native-community/datetimepicker": "7.2.0",
"@react-native-community/geolocation": "^3.0.6",
"@react-native-community/slider": "4.4.2",
"@react-native-picker/picker": "2.4.10",
"@react-navigation/bottom-tabs": "^6.5.8",
"@react-navigation/material-top-tabs": "^6.6.4",
"@react-navigation/native": "^6.1.6",
"@react-navigation/native-stack": "^6.9.12",
"@reduxjs/toolkit": "^1.9.5",
"axios": "^1.5.0",
"expo": "^49.0.0",
"expo-build-properties": "~0.8.3",
"expo-constants": "~14.4.2",
"expo-dev-client": "~2.4.11",
"expo-device": "~5.4.0",
"expo-location": "~16.1.0",
"expo-notifications": "~0.20.1",
"expo-permissions": "~14.2.1",
"expo-status-bar": "~1.6.0",
"expo-task-manager": "~11.3.0",
"libphonenumber-js": "^1.10.44",
"lodash.debounce": "^4.0.8",
"moment-timezone": "^0.5.43",
"pinar": "^0.12.2",
"react": "18.2.0",
"react-native": "0.72.5",
"react-native-actionsheet": "^2.4.2",
"react-native-animatable": "^1.3.3",
"react-native-chart-kit": "^6.12.0",
"react-native-element-dropdown": "^2.9.0",
"react-native-gesture-handler": "~2.12.0",
"react-native-gifted-chat": "^2.4.0",
"react-native-google-mobile-ads": "^12.3.0",
"react-native-maps": "1.7.1",
"react-native-pager-view": "6.2.0",
"react-native-paper": "^5.10.0",
"react-native-progress": "^5.0.0",
"react-native-progress-steps": "^1.3.4",
"react-native-ratings": "^8.1.0",
"react-native-reanimated": "~2.14.4",
"react-native-safe-area-context": "4.6.3",
"react-native-select-dropdown": "^3.4.0",
"react-native-svg": "13.9.0",
"react-native-svg-transformer": "^1.1.0",
"react-native-swiper": "^1.6.0",
"react-native-tab-view": "^3.5.2",
"react-native-vector-icons": "^10.0.0",
"react-redux": "^8.1.1",
"typescript": "^5.1.3"
},
"devDependencies": {
"@babel/core": "^7.20.0",
"@types/react-native": "^0.72.5"
},
"private": true
}
I watched tutorials and found that I need to install the npm package "react-native-safe-area-context"
which I did. However, the issue is still not resolved.