Closed shuijinliuxi closed 2 years ago
Our app has many reducer, but I just want to save the login.user, so I set the code:
const userPersistConfig = { key: 'login', storage, whitelist: ['user'] }; const appPersistConfig = { key: 'app', storage, whitelist: ['loginReducer'] }; const rootReducer = combineReducers({ ...reducers, loginReducer: persistReducer(userPersistConfig, loginReducer) }); const persistedReducer = persistReducer(appPersistConfig, rootReducer);
but it not work…… It save the all data of loginReducer.
did you got solutions for this bro? because i also want to set up like this. @shuijinliuxi
Our app has many reducer, but I just want to save the login.user, so I set the code:
but it not work…… It save the all data of loginReducer.