redux-persist-expo-filesystem
v2.0.1
Published
Redux-Persist storage engine using Expo filesystem that removes the need to eject Expo/CRNA app
Downloads
15,073
Maintainers
Readme
Redux-Persist for Expo Filesystem
Persist redux store to filesystem because of the following android limitation #199
Existing filesystem for redux-persist require ejecting of Expo apps due to react-native linking.
Comes with typescript definitions.
Compatibility
- v2.0.0 imports from
expo-file-system
unimodule and is compatible withexpo
>= 33 orexpo-file-system
>= 5 - v1.0.1 imports from
expo
and is compatible withexpo
27 to 33 (inclusive)
Setup
- Install: yarn add redux-persist-expo-filesystem
- Make sure expo is a peer dependency
- Usage below:
import ExpoFileSystemStorage from "redux-persist-expo-filesystem";
const persistConfig = {
key: "root",
storage: ExpoFileSystemStorage,
};
const store = createStore(persistReducer(persistConfig, rootReducer));