What you are reporting:
What you think should happen:
handleClose should be called with the current context of the component.
What actually happens:
handleClose is called with the old context of the container.
React Hot Loader version:
^3.0.0-beta.6
Run these commands in the project folder and fill in their results:
node -v: v7.9.0npm -v: v4.2.0Then, specify:
git clone [email protected]:gajus/sanity-test.git
cd ./sanity-test
npm run install
npm run dev
Click "Click me" button.
Expected result: movie prop is not null.
Curent result movie prop is null.
The lack of context binding is visible in the code transpilation difference without/ with react-hot-loader/babel https://gist.github.com/gajus/2d0867f326d5c69702f057c7cd7cf15f/revisions
The real issue is documented here. https://github.com/gaearon/react-proxy/issues/69
I have tested it with React Hot Loader v4 and it is now fixed.
Most helpful comment
The real issue is documented here. https://github.com/gaearon/react-proxy/issues/69