0

I am developing an app with ReactNative using asyncStorage, on Android it is working fine, I have the problem on iOS, I can't solve the problem: Error: [@ RNC / AsyncStorage]: NativeModule: AsyncStorage is null.

Here is a picture of the error

This is Error Messaje in iPhone X

I've tried all the instructions you put in the error message, and I've looked for the same error and can't find the solution. Let's see if anyone has had the same experience with this error and can help me, thank you very much.

More information:

  • I'm not using expo
  • React Native version 61.5
Muhammad Iqbal
  • 1,394
  • 1
  • 14
  • 34
xmi
  • 21
  • 1
  • 6

1 Answers1

1

Try adding the following line on your ios/Podfile:

[...]
target 'YourApp' do
  #The line below
  pod 'RNCAsyncStorage', :path => '../node_modules/@react-native-community/async-storage'
  
  target 'YourAppTests' do
    inherit! :complete
    # Pods for testing
  end
[...]

then cd ios && pod install

Make sure you have cocoapods installed and you're using pods on your project.

  • 1
    I have installed cocoapods, I have added those lines to the podfile file, but I still get the same error – xmi Aug 20 '20 at 12:33