Sometimes we need to get store after use actions. Actually it's useful for testing containers. I found method replaceReducer, but it's not worked.
Method replaceReducer do nothing
replaceReducer (nextReducer) {
if (!isFunction(nextReducer)) {
throw new Error('Expected the nextReducer to be a function.')
}
}
I propose create local reducer and wrap state when get new action.
InitialState is default value for reducer.
This will make it convenient to receive a modified store.
Sometimes we need to get store after use actions. Actually it's useful for testing containers. I found method
replaceReducer
, but it's not worked. MethodreplaceReducer
do nothingI propose create local reducer and wrap state when get new action. InitialState is default value for reducer. This will make it convenient to receive a modified store.