const appReducer = combineReducers({
todos,
visibilityFilter
});
const rootReducer = ( state, action ) => {
if ( action.type === LOG_OUT ) {
state = undefined;
}
return appReducer(state, action)
}
const store = createStore(rootReducer);