Null AsyncStorage when specifying react-native-community/async-storage
See original GitHub issueJust upgraded from 5.10.0 to 6.0.0. I’m using the following versions:
expo: 3.11.1 react: 16.9.0 react-native: 0.61.4 redux: 4.0.4 redux-persist: 6.0.0
After make the changes as explained in the documentation I started to get an red screen error with the message “AsyncStorage is null”
I changed my code as shown in the documentation:
import AsyncStorage from '@react-native-community/async-storage';
const persistConfig = {
storage: AsyncStorage
};
I don’t know if this problem is related to redux-persist or to async-store. Anyway I’m describing the problema here first. Hope I can get some help. Thanks.
Issue Analytics
- State:
- Created 4 years ago
- Comments:11
Top Results From Across the Web
react native - NativeModule: AsyncStorage is null, with @RNC ...
To fix this issue try these steps: -Run `react-native link @react-native-community/async-storage` in the project root. -Rebuild and restart the ...
Read more >How To Use React Native AsyncStorage | Jscrambler - Medium
AsyncStorage is a simple, asynchronous, unencrypted by default module that allows you to persist data offline in React Native apps. Learn more about...
Read more >AsyncStorage - React Native
AsyncStorage is an unencrypted, asynchronous, persistent, key-value storage system that is global to the app. It should be used instead of ...
Read more >AsyncStorage - React Native Express
This will return a Promise containing a string, or null if no data has been stored yet ... import AsyncStorage from '@react-native-community/async-storage'.
Read more >React Native AsyncStorage Example: When I Die App - Soshace
import AsyncStorage from '@react-native-community/async-storage';. Define a new state for the component.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
import {AsyncStorage} from 'react-native';
seems to work ok now with expo 36Yes, let’s wait for the upgrade =)