Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

React 16.9.0 support webpack plugin #1319

Closed
Bnaya opened this issue Aug 9, 2019 · 2 comments · Fixed by #1320
Closed

React 16.9.0 support webpack plugin #1319

Bnaya opened this issue Aug 9, 2019 · 2 comments · Fixed by #1320
Assignees

Comments

@Bnaya
Copy link
Contributor

Bnaya commented Aug 9, 2019

Due to changes in react 16.9, the patch in the webpack plugin no longer works
Also, seems like they baked react-refresh code into react-dom, that is very similar to this code,
So maybe with some tweaks this patch won't be needed at all?

The change:

if (child.tag === Fragment ? element.type === REACT_FRAGMENT_TYPE : child.elementType === element.type)
        if (child.tag === Fragment ? element.type === REACT_FRAGMENT_TYPE : child.elementType === element.type || (
        // Keep this check inline so it only runs on the false path:
        isCompatibleFamilyForHotReloading(child, element))) 

Related: hot-loader/react-dom#14

@Bnaya
Copy link
Contributor Author

Bnaya commented Aug 9, 2019

NOTE: master has failing tests,
https://travis-ci.org/gaearon/react-hot-loader/jobs/567475841#L750-L751
But the ci.sh exit with exit code 0 and not 1.

@theKashey
Copy link
Collaborator

So maybe with some tweaks this patch won't be needed at all?

Out logic is a bit different. It's possible to change our API to match react expectations, but not quite like this.

@theKashey theKashey self-assigned this Aug 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants