I had set InitialState in my redux createStore method ,and I corresponding InitialState as second arguments
I got a error in browser:
Un
I had the same error but I didn't include a default case
function generate(state={} ,action) { switch (action.type) { case randomNumber: return { ...state, random: action.payload } default: // need this for default case return state } }