th3rdwave / react-native-safe-area-context

A flexible way to handle safe area insets in JS. Also works on Android and Web!
MIT License
2.14k stars 197 forks source link

Invariant Violation: requireNativeComponent: "RNCSafeAreaProvider" was not found in the UIManager. #438

Closed ayanokoujifl closed 11 months ago

ayanokoujifl commented 12 months ago

package.json

Dependencies:

    "@gorhom/bottom-sheet": "^4.5.1",
    "expo": "^49.0.13",
    "expo-dev-client": "~0.8.6",
    "expo-font": "~10.0.4",
    "expo-location": "~14.0.1",
    "expo-splash-screen": "~0.14.1",
    "expo-status-bar": "~1.2.0",
    "native-base": "^3.4.28",
    "react": "18.2.0",
    "react-native": "0.72.5",
    "react-native-gesture-handler": "~2.12.0",
    "react-native-reanimated": "~3.3.0",
    "react-native-safe-area-context": "^3.3.2",
    "react-native-screens": "~3.22.0",
    "react-native-svg": "12.1.1"

App.jsx

export default function App() {
  return (
     <SafeAreaProvider>
      <NativeBaseProvider>
        <Home />
      </NativeBaseProvider>
    </SafeAreaProvider>
  )
}

I have already made several changes related to the dependency versions. I thought it could be related to the native base, but apparently it is related to the safe area. Need help.

Complete error:

Invariant Violation: requireNativeComponent: "RNCSafeAreaProvider" was not found in the UIManager. This error is located at: in RNCSafeAreaProvider (created by SafeAreaProvider) in SafeAreaProvider (created by App) in App (created by withDevTools(App)) in withDevTools(App) in RCTView (created by View) in View (created by AppContainer) in RCTView (created by View) in View (created by AppContainer) in AppContainer in main(RootComponent), js engine: hermes

jacobp100 commented 11 months ago

Run the pod install step, then clean and rebuild the native code