You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to save in storage one full reducer, and only one field from other reducer. How can I do this? I found e.g. this gh issue, but all attempts (from gh link and other sources) turned out to be a failure.
import{getPersistConfig}from'redux-deep-persist';constconfig=getPersistConfig({key: 'root',storage: LocalStorage,// whatever storage you usewhitelist: ['a1.b1.c1','a2.b2.c2','a3',
'a4.b4.c4.no.matter.how.deep.you.go
],
rootReducer, // your root reducer must be also passed here
... // any other props from original redux-persist config, omitting the stateReconciler
})
I want to save in storage one full reducer, and only one field from other reducer. How can I do this? I found e.g. this gh issue, but all attempts (from gh link and other sources) turned out to be a failure.
const persistConfig = { key: "root", storage, whitelist: ["first"], transforms: [createWhitelistFilter("second", ["counter"])] };
codesandbox example
It works for first reducer, nothing happens with the second, when I want to storage only counter field from reducer.
Any Ideas?
The text was updated successfully, but these errors were encountered: