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
We've seen too many cases where users call configureStore({reducer, middleware: [myMiddleware]}), and accidentally blow away the defaults.
Let's remove that form and only allow callbacks. We already did that for enhancers, so same idea.
Users can still do middleware: () => [myMiddleware] if they really want to, but that at least forces them to make use of the callback form, and reduces the chance of it being a mistake.
The text was updated successfully, but these errors were encountered:
markerikson
changed the title
Remove array form for configureStore.middleware argument
[RED-32] Remove array form for configureStore.middleware argument
Sep 25, 2023
We've seen too many cases where users call
configureStore({reducer, middleware: [myMiddleware]})
, and accidentally blow away the defaults.Let's remove that form and only allow callbacks. We already did that for
enhancers
, so same idea.Users can still do
middleware: () => [myMiddleware]
if they really want to, but that at least forces them to make use of the callback form, and reduces the chance of it being a mistake.RED-32
The text was updated successfully, but these errors were encountered: