I am using redux, react-redux and redux thunk
for store
management in my react native project, there is deferent reducers
and actions
. How I reset
the entire store
during logout
Is there any methods like createStore()
to destroy a store?
please share possible solutions
Thanks
The below solution worked for me,
import reduxReset from 'redux-reset'
const enHanceCreateStore = compose(
applyMiddleware(thunk),
reduxReset()
)(createStore)
const store = enHanceCreateStore(reducers)
dispatch reset action
store.dispatch({
type: 'RESET'
})