[DevTools] Record Suspense node for roots in legacy renderers#34516
Merged
eps1lon merged 2 commits intofacebook:mainfrom Sep 18, 2025
Conversation
0b28992 to
7448b1b
Compare
eps1lon
commented
Sep 18, 2025
| pendingUnmountedIDs.push(id); | ||
| const isRoot = parentIDStack.length === 0; | ||
| if (isRoot) { | ||
| pendingUnmountedRootID = id; |
Collaborator
Author
There was a problem hiding this comment.
pendingUnmountedRootID was never actually written to. The root was just unmounted by virtue of being included in the normal unmount operation. There wasn't anything special to be done with the root until now.
A single unmounted root ID is sound since we always flush operations after unmounting a component.
sebmarkbage
approved these changes
Sep 18, 2025
…tree Mostly so that we don't trigger unnecessary warnings in older React versions.
7448b1b to
d94b3cf
Compare
This was referenced Sep 19, 2025
unstubbable
pushed a commit
to vercel/next.js
that referenced
this pull request
Sep 19, 2025
[diff facebook/react@84af9085...d415fd3e](facebook/react@84af908...d415fd3) <details> <summary>React upstream changes</summary> - facebook/react#34536 - facebook/react#34534 - facebook/react#34531 - facebook/react#34499 - facebook/react#34523 - facebook/react#34511 - facebook/react#34516 - facebook/react#34455 - facebook/react#34488 - facebook/react#34521 </details>
github-actions bot
pushed a commit
to code/lib-react
that referenced
this pull request
Sep 21, 2025
…ok#34516) DiffTrain build for [03a96c7](facebook@03a96c7)
github-actions bot
pushed a commit
to code/lib-react
that referenced
this pull request
Sep 21, 2025
…ok#34516) DiffTrain build for [03a96c7](facebook@03a96c7)
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.
Stacked on #34455
Mostly so that we don't trigger unnecessary warnings in older React versions.
We could avoid the additional capability in favor checking if the root exists in the Suspense tree but that may hide legit bugs.