9 Concepts) Session Storage + Persistence Flashcards
data can be stored locally using what object property?
The localStorage property of the window object
What package gives you the ability to keep data if a page refreshes?
“redux-persist”
What function from “redux-persist” allows one to persist a project’s store? What are its args?
persistStore(store)
What function from “redux-persist” allows one to persist a projects root reducer? What are its args?
persistReducer(persistConfig, rootReducer)
What React component must be wrapped around the app component to allow persistor to work?
PersistGate persistor={persistor}
Why should you put a component’s state data into redux even when that data may not be used in any other components?
It makes the data easier to test