1.0.8 • Published 4 years ago
redux-persist-capacitor-storage v1.0.8
Redux Persist Capacitor Filesystem Storage
Redux Persist storage engine working as an adapter to Capacitor's Filesystem API
Install
yarn add @capacitor/core redux-persist-capacitor-storage
Simple use-case with auth state
import CapacitorStore from "redux-persist-capacitor-storage";
import { persistReducer } from "redux-persist";
import { auth } from "./auth";
const authPersistConfig = {
key: "auth",
storage: CapacitorStore
};
const appReducer = combineReducers({
auth: persistReducer(authPersistConfig, auth)
});