Inline some internals, reduce shared/ utilities between isomorphic and renderers#9903
Merged
gaearon merged 11 commits intofacebook:masterfrom Jun 9, 2017
Merged
Inline some internals, reduce shared/ utilities between isomorphic and renderers#9903gaearon merged 11 commits intofacebook:masterfrom
gaearon merged 11 commits intofacebook:masterfrom
Conversation
This breaks IE8. We don't support it.
It was added temporarily to avoid Stack shared state issues across renderers. Not a problem anymore.
It's unlikely we'll deprecate anything else on React.* object soon.
It's only used in one place in isomorphic. It's used more broadly in Stack so we move it there to die.
gaearon
commented
Jun 9, 2017
|
|
||
| src/shared/utils/__tests__/KeyEscapeUtils-test.js | ||
| * should properly escape and wrap user defined keys | ||
| * should properly unescape and unwrap user defined keys |
Collaborator
Author
There was a problem hiding this comment.
I didn't bother porting this test, for isomorphic (which is where this code leaves on) it's only testing flatten which is not even officially exposed. But I can write it against flatten specifically if somebody cares.
sebmarkbage
approved these changes
Jun 9, 2017
| return '$' + escapedString; | ||
| } | ||
|
|
||
| var unescapeInDev = emptyFunction; |
Contributor
There was a problem hiding this comment.
This could just be null I guess. But doesn't matter since after Stack is deleted we can probably just inline this?
Collaborator
Author
There was a problem hiding this comment.
Let's revisit when/if rewrite Children.
koba04
added a commit
to koba04/react
that referenced
this pull request
Jun 12, 2017
koba04
added a commit
to koba04/react
that referenced
this pull request
Jun 29, 2017
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.
See individual commits.
The goal is to narrow down those utilities because they are copied into both bundles.
While we're at it, also making some things DEV-only.
There is a bit more duplication than I'd like, but it's partly due to Stack.
For things like Symbols, I don't think modules are super useful.
Note: this 441a04e breaks IE8 hard.