gaearon / react-hot-boilerplate

Minimal live-editing example for React
MIT License
3.91k stars 879 forks source link

'react-hot-loader/babel' seems useless in `.babelrc` #115

Closed SidKwok closed 7 years ago

SidKwok commented 7 years ago

If I remove "plugins": ["react-hot-loader/babel"], the HMR also run correctly.

Will the plugin be added automatically?

I want to use babel's env to remove this plugin in my production, so will it be removed from my production?

react-hot-loader 3.0.0@beta.6

calesce commented 7 years ago

HMR runs correctly but the point of the Babel plugin is to prevent stateful React components from unmounting on HMR updates, so they retain their state.