Remove hydrate option from createRoot#22878
Merged
salazarm merged 5 commits intofacebook:mainfrom Dec 7, 2021
Merged
Conversation
salazarm
commented
Dec 7, 2021
| if (gate(flags => flags.enableSyncDefaultUpdates)) { | ||
| expect(Scheduler).toHaveYielded([2, 'a:two']); | ||
| } else { | ||
| // Not sure about this... |
Contributor
Author
There was a problem hiding this comment.
@acdlite Unsure why I needed to do this. Could you enlighten me please? :)
Collaborator
There was a problem hiding this comment.
hydrateRoot is synchronous whereas root.render is not
|
Comparing: c7917fe...7eb0aba Critical size changesIncludes critical production bundles, as well as any change greater than 2%:
Significant size changesIncludes any change greater than 0.2%: (No significant changes) |
acdlite
approved these changes
Dec 7, 2021
Contributor
|
We should probably keep a warning if someone passes it since it was around in early versions a long time. |
Contributor
|
Nice. It's like taking a shower. Feels fresh. |
facebook-github-bot
pushed a commit
to facebook/react-native
that referenced
this pull request
Dec 14, 2021
Summary: This sync includes the following changes: - **[f2a59df](facebook/react@f2a59df48 )**: Remove unstableAvoidThisFallback from OSS ([#22884](facebook/react#22884)) //<salazarm>// - **[24dd07b](facebook/react@24dd07bd2 )**: Add custom element property support behind a flag ([#22184](facebook/react#22184)) //<Joey Arhar>// - **[72e48b8](facebook/react@72e48b8e1 )**: Fix: Don't skip writing updated package.json //<Andrew Clark>// - **[e39b2c8](facebook/react@e39b2c899 )**: Fix peer deps for use-sync-external-store //<Andrew Clark>// - **[ec78b13](facebook/react@ec78b135f )**: Don't override use-sync-external-store peerDeps ([#22882](facebook/react#22882)) //<Andrew Clark>// - **[5041c37](facebook/react@5041c37d2 )**: Remove hydrate option from createRoot ([#22878](facebook/react#22878)) //<salazarm>// - **[3f9480f](facebook/react@3f9480f0f )**: enable continuous replay flag ([#22863](facebook/react#22863)) //<salazarm>// - **[4729ff6](facebook/react@4729ff6d1 )**: Implement identifierPrefix option for useId ([#22855](facebook/react#22855)) //<Andrew Clark>// - **[ed00d2c](facebook/react@ed00d2c3d )**: Remove unused flag ([#22854](facebook/react#22854)) //<Dan Abramov>// - **[0cc724c](facebook/react@0cc724c77 )**: update ReactFlightWebpackPlugin to be compatiable with webpack v5 ([#22739](facebook/react#22739)) //<Michelle Chen>// - **[4e6eec6](facebook/react@4e6eec69b )**: fix: document can be `null`, not just `undefined` ([#22695](facebook/react#22695)) //<Simen Bekkhus>// Changelog: [General][Changed] - React Native sync for revisions c1220eb...a049aa0 jest_e2e[run_all_tests] Reviewed By: rickhanlonii Differential Revision: D33062386 fbshipit-source-id: 37e497947efad5696c251096da8a92ccdc6dcea7
7 tasks
zhengjitf
pushed a commit
to zhengjitf/react
that referenced
this pull request
Apr 15, 2022
* remove hydrate: true option * remove missed comment * lint * warning * circumvent flow
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.
Summary
Removing
hydrate: trueandhydrateOptionsfromcreateRoot. InsteadhydrateRootshould be used.How did you test this change?
Updated jest tests. There is one
useMutableSourceHydrationtest that I'm unsure about. Added a comment above it.