react-redux-complete-example icon indicating copy to clipboard operation
react-redux-complete-example copied to clipboard

In createReducer, why 2 nested functions instead of just 1?

Open ppo opened this issue 6 years ago • 0 comments

In createReducer, why 2 nested functions instead of just 1?

Why (initialState) => (reducerMap) => (state = initialState, action) => instead of (initialState, reducerMap) => (state = initialState, action) =>?
As it's anyway always used as createReducer(…)({…}), right?

ppo avatar Sep 13 '19 11:09 ppo