Add react-dom-unstable-native-dependencies#10138
Merged
gaearon merged 6 commits intofacebook:masterfrom Jul 12, 2017
Merged
Conversation
react-native-web and react-primitives currently access a few internals for shimming DOM events into native ones. Changes in react@16 packaging hide these internals completely. This change adds a submodule to react-dom, unstable-native-dependencies that includes the necessary modules to continue enabling that method of dom-native event injection.
Collaborator
It would be useful if we wanted to use these modules in www too. |
gaearon
requested changes
Jul 11, 2017
| @@ -0,0 +1,7 @@ | |||
| 'use strict'; | |||
Collaborator
There was a problem hiding this comment.
Since there's a new file we need to add it to whitelist in package.json, or it would get ignored on publish.
scripts/rollup/bundles.js
Outdated
| 'src/shared/**/*.js', | ||
| ], | ||
| }, | ||
| /* React DOM internals required for shimming react-native apps into the react-dom renderer */ |
Collaborator
There was a problem hiding this comment.
Maybe let's say "required for react-native-web" for explicitness.
Collaborator
|
Is there a smoke test we can add? Otherwise I'm worried we'll break it. |
In order to get some sort of smoke testing on react-dom-unstable-native-dependencies, update ResponderEventPlugin-test to use the "public" interfaces provided by react-dom and the new react-dom/unstable-native dependencies Also adds the missing references in package.json as well as missing files required for unittests to do imports correctrly Also exports injectComponentTree() which is required for the unittests to re-set the shared component state between runs.
Contributor
Author
|
Still trying to figure out the fbEntry business. When I add it and try to build, I get the following unhandled error when trying to build: Any ideas? |
Collaborator
|
Please |
gaearon
approved these changes
Jul 12, 2017
Collaborator
|
LGTM, thank you for driving this! |
Contributor
|
I really appreciate this. Thank you! |
Closed
19 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
react-native-web and react-primitives currently access a few internals
for shimming DOM events into native ones. Changes in react@16 packaging
hide these internals, which has made it difficult for these projects to upgrade.
change adds a submodule to react-dom, unstable-native-dependencies that
includes the necessary modules to continue enabling that method of
dom-native event injection.
The bundle config is currently a bit of dogscience. The one thing I really changes were:
which was required to inject the shared ComponentTree into this module.