Richard Miles
1 min readSep 28, 2018

--

Great article!

Would possibly opt for a more object centric approach to type check e.g.

const types = {
'SIMPLE_ACTION': {
result: action.payload
}
}
return types[action.type] || state

--

--

Richard Miles
Richard Miles

No responses yet