Open GuillaumeCisco opened 5 years ago
Known issue, and one of 3 major ones. The plain was to solve it in v5, but it was delayed a bit.
Thanks @theKashey, it somehow reassures me. Can you link me to the known issue.
This is the idea - https://github.com/gaearon/react-hot-loader/issues/1138
Description
What you are reporting:
React hot loading bug with emotion when using a splitted file class extending from another one.
Expected behavior
What you think should happen:
Classic react hot loading
Actual behavior
What actually happens:
Fail to react hot load
The emotion import is no longer available.
Environment
React Hot Loader version: 4.6.3 Run these commands in the project folder and fill in their results:
node -v
: v11.10.0npm -v
: 6.7.0Then, specify:
Reproducible Demo
Here is a repo where you can see it in action: https://github.com/GuillaumeCisco/emotion-react-hot-loader-bug This repo is a light version of our project, I tried to remove the maximum boilerplate code. The interesting folders for this issue will be
src/app
andpackages
. This project uses a SSR Stream configuration.Follow the README, simply run
yarn install
,yarn start
go tohttp:localhost:3000
and try modifying the fileabstract.js
. You will see the error. You can see it can work correctly without splitting files using theSurnameWithabstract
component fromsrc/app/index.js
, simply uncomment it and try modifiying whatever files.