diff --git a/content/docs/hooks-reference.md b/content/docs/hooks-reference.md index 90091d8d..7a3a0dde 100644 --- a/content/docs/hooks-reference.md +++ b/content/docs/hooks-reference.md @@ -246,9 +246,7 @@ function reducer(state, action) { case 'reset': return init(action.payload); default: - // A reducer must always return a valid state. - // Alternatively you can throw an error if an invalid action is dispatched. - return state; + throw new Error(); } }