Recently if "hot" is turned off but you are in development mode, react-hot-loader starts logging
React-Hot-Loader: misconfiguration detected, using production version in not production environment.
This is not actually a misconfiguration for all cases. Devs should have the option to turn off hot reloading during development and it makes sense to just have react-hot-loader fall back to production mode. Also, these errors pop up all over the place during testing unless you have your NODE_ENV explicitly set to 'test'. I'm also not sure what the purpose of the logs are since if hot is turned off, react hot loader should not interfere at all.
hot is turned off, react hot loader should not interfere at all.
The idea is to explain why it does not work as expected :)
An easy way to fix - dont use RHL if you are not going to
const ExportedApp = process.env.NODE_ENV === 'development'
? hot(App) // error is thrown by `hot`
: App;
export default App;
```
Unfortunately we have a lot of react roots so doing that workaround at each one is going to add a lot of confusion. We would need our own hoc that does this.
Feel free to copy-paste root/hot sources and make it work for you.
Most helpful comment
The idea is to explain why it does not work as expected :)
An easy way to fix - dont use RHL if you are not going to
```