You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: docs/recipes/ReducingBoilerplate.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -528,4 +528,4 @@ function createReducer(initialState, handlers) {
528
528
529
529
This wasn't difficult, was it? Redux doesn't provide such a helper function by default because there are many ways to write it. Maybe you want it to automatically convert plain JS objects to Immutable objects to hydrate the server state. Maybe you want to merge the returned state with the current state. There may be different approaches to a “catch all” handler. All of this depends on the conventions you choose for your team on a specific project.
530
530
531
-
The Redux reducer API is `(state, action) => state`, but how you create those reducers is up to you.
531
+
The Redux reducer API is `(state, action) => newState`, but how you create those reducers is up to you.
0 commit comments