microsoft / redux-dynamic-modules

Modularize Redux by dynamically loading reducers and middlewares.
https://redux-dynamic-modules.js.org
MIT License
1.07k stars 116 forks source link

React 16.13 incompatibility #138

Open ljosberinn opened 4 years ago

ljosberinn commented 4 years ago

Due to the recent React 16.13 update, the default behaviour of DynamicModules leads to a warning.

react_devtools_backend.js:6 Warning: Cannot update a component from inside the function body of a different component.
    in DynamicModuleLoaderImpl (created by Context.Consumer)
    in DynamicModuleLoader (created by RedactedComponent)

It's probably easily resolved by removing the default behaviour and just keeping the StrictMode mode, essentially removing the strictMode prop too. At least within StrictMode and letting the modules know about it we don't see this warning.