-
Notifications
You must be signed in to change notification settings - Fork 46.4k
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
Fix suspense replaying forward refs #26535
Merged
acdlite
merged 10 commits into
facebook:main
from
hansottowirtz:fix-suspense-replaying-forward-refs
Apr 2, 2023
Merged
Fix suspense replaying forward refs #26535
acdlite
merged 10 commits into
facebook:main
from
hansottowirtz:fix-suspense-replaying-forward-refs
Apr 2, 2023
Commits on Apr 2, 2023
-
Configuration menu - View commit details
-
Copy full SHA for 9829d02 - Browse repository at this point
Copy the full SHA 9829d02View commit details -
Configuration menu - View commit details
-
Copy full SHA for d561e02 - Browse repository at this point
Copy the full SHA d561e02View commit details -
Configuration menu - View commit details
-
Copy full SHA for ede13bc - Browse repository at this point
Copy the full SHA ede13bcView commit details -
Configuration menu - View commit details
-
Copy full SHA for 5f0fbbf - Browse repository at this point
Copy the full SHA 5f0fbbfView commit details -
Configuration menu - View commit details
-
Copy full SHA for 58dd0f4 - Browse repository at this point
Copy the full SHA 58dd0f4View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4aad797 - Browse repository at this point
Copy the full SHA 4aad797View commit details -
Configuration menu - View commit details
-
Copy full SHA for 82ab9e0 - Browse repository at this point
Copy the full SHA 82ab9e0View commit details -
Unified replay impl for function component types
The only difference between a component wrapped in forwardRef and one that's not is that the former is passed a ref prop. To make it less likely that the behavior diverges, I unified replayFunctionComponent and replayForwardRefComponent into a single function again. We should do this for the regular begin phase functions, too: instead of completely forked path for regular functions and forwardRef, they should both converge into the same path. We already do this for SimpleMemoComponent. I also added more test coverage for the different component types because I noticed we were missing some. Also noticed that legacy context wasn't being handled during the replay of a function component wrapped with `memo` and added a test for that.
Configuration menu - View commit details
-
Copy full SHA for 87a01ab - Browse repository at this point
Copy the full SHA 87a01abView commit details -
Unify FunctionComponent and SimpleMemoComponent cases
These are the same thing.
Configuration menu - View commit details
-
Copy full SHA for f32ae1d - Browse repository at this point
Copy the full SHA f32ae1dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 7875d3d - Browse repository at this point
Copy the full SHA 7875d3dView commit details
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.