I want to store user related properties in sessionStorage and other properties in localStorage. I was able to store all properties in localStorage using persist with this below configuration
import reducers from './reducer';
import { persistStore, persistReducer } from 'redux-persist';
import storage from 'redux-persist/lib/storage';
import autoMergeLevel2 from 'redux-persist/lib/stateReconciler/autoMergeLevel2';
const persistConfig = {
key: 'root',
storage: storage,
stateReconciler: autoMergeLevel2 // see "Merge Process" section for details.
};
const pReducer = persistReducer(persistConfig, reducers);
Can someone please tell me how to configure both sessionStorage and localStorage in persist ?