Skip to content

[Fiber] Stash ThenableState on the Dependencies Object for Use By DevTools#30866

Merged
sebmarkbage merged 1 commit into
react:mainfrom
sebmarkbage:trackuseindev
Sep 3, 2024
Merged

[Fiber] Stash ThenableState on the Dependencies Object for Use By DevTools#30866
sebmarkbage merged 1 commit into
react:mainfrom
sebmarkbage:trackuseindev

Conversation

@sebmarkbage

@sebmarkbage sebmarkbage commented Sep 3, 2024

Copy link
Copy Markdown
Contributor

This lets us track what a Component might suspend on from DevTools. We could already collect this by replaying a component's Hooks but that would be expensive to collect from a whole tree.

The thenables themselves might contain useful information but mainly we'd want access to the _debugInfo on the thenables which might contain additional information from the server.

https://github.com/facebook/react/blob/19bd26beb689e554fceb0b929dc5199be8cba594/packages/shared/ReactTypes.js#L114

In a follow up we should really do something similar in Flight to transfer use() on the debugInfo of that Server Component.

@sebmarkbage sebmarkbage requested a review from acdlite September 3, 2024 18:55
@vercel

vercel Bot commented Sep 3, 2024

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
react-compiler-playground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 3, 2024 7:14pm

@react-sizebot

react-sizebot commented Sep 3, 2024

Copy link
Copy Markdown

Comparing: e0a07e9738b2ec2ea5cf4872406b465d677bfe2c...c13e62527c33c683945c3b25b08a2293fdcb7173

Critical size changes

Includes critical production bundles, as well as any change greater than 2%:

Name +/- Base Current +/- gzip Base gzip Current gzip
oss-stable/react-dom/cjs/react-dom.production.js = 6.68 kB 6.68 kB +0.05% 1.82 kB 1.82 kB
oss-stable/react-dom/cjs/react-dom-client.production.js = 501.40 kB 501.40 kB = 89.99 kB 89.99 kB
oss-experimental/react-dom/cjs/react-dom.production.js = 6.69 kB 6.69 kB = 1.83 kB 1.83 kB
oss-experimental/react-dom/cjs/react-dom-client.production.js = 508.52 kB 508.52 kB = 91.16 kB 91.16 kB
facebook-www/ReactDOM-prod.classic.js = 596.16 kB 596.16 kB = 105.69 kB 105.69 kB
facebook-www/ReactDOM-prod.modern.js = 572.44 kB 572.44 kB = 101.88 kB 101.88 kB

Significant size changes

Includes any change greater than 0.2%:

(No significant changes)

Generated by 🚫 dangerJS against 978ab6a

@sebmarkbage sebmarkbage merged commit 8d68da3 into react:main Sep 3, 2024
github-actions Bot pushed a commit that referenced this pull request Sep 3, 2024
…Tools (#30866)

This lets us track what a Component might suspend on from DevTools. We
could already collect this by replaying a component's Hooks but that
would be expensive to collect from a whole tree.

The thenables themselves might contain useful information but mainly
we'd want access to the `_debugInfo` on the thenables which might
contain additional information from the server.

https://github.com/facebook/react/blob/19bd26beb689e554fceb0b929dc5199be8cba594/packages/shared/ReactTypes.js#L114

In a follow up we should really do something similar in Flight to
transfer `use()` on the debugInfo of that Server Component.

DiffTrain build for [8d68da3](8d68da3)
github-actions Bot pushed a commit that referenced this pull request Sep 3, 2024
…Tools (#30866)

This lets us track what a Component might suspend on from DevTools. We
could already collect this by replaying a component's Hooks but that
would be expensive to collect from a whole tree.

The thenables themselves might contain useful information but mainly
we'd want access to the `_debugInfo` on the thenables which might
contain additional information from the server.

https://github.com/facebook/react/blob/19bd26beb689e554fceb0b929dc5199be8cba594/packages/shared/ReactTypes.js#L114

In a follow up we should really do something similar in Flight to
transfer `use()` on the debugInfo of that Server Component.

DiffTrain build for commit 8d68da3.
gnoff pushed a commit to vercel/next.js that referenced this pull request Sep 12, 2024
**breaking change for canary users: Bumps peer dependency of React from
`19.0.0-rc-7771d3a7-20240827` to `19.0.0-rc-94e652d5-20240912`**

[diff
react/react@7771d3a7...94e652d5](react/react@7771d3a...94e652d)

<details>
<summary>React upstream changes</summary>

- react/react#30952
- react/react#30950
- react/react#30946
- react/react#30934
- react/react#30947
- react/react#30945
- react/react#30938
- react/react#30936
- react/react#30879
- react/react#30888
- react/react#30931
- react/react#30930
- react/react#30832
- react/react#30929
- react/react#30926
- react/react#30925
- react/react#30905
- react/react#30900
- react/react#30910
- react/react#30906
- react/react#30899
- react/react#30919
- react/react#30708
- react/react#30907
- react/react#30897
- react/react#30896
- react/react#30895
- react/react#30887
- react/react#30889
- react/react#30893
- react/react#30892
- react/react#30891
- react/react#30882
- react/react#30881
- react/react#30870
- react/react#30849
- react/react#30878
- react/react#30865
- react/react#30869
- react/react#30875
- react/react#30800
- react/react#30762
- react/react#30831
- react/react#30866
- react/react#30853
- react/react#30850
- react/react#30847
- react/react#30842
- react/react#30837
- react/react#30848
- react/react#30844
- react/react#30839
- react/react#30802
- react/react#30841
- react/react#30827
- react/react#30826
- react/react#30825
- react/react#30824
- react/react#30840
- react/react#30838
- react/react#30836
- react/react#30819
- react/react#30816
- react/react#30814
- react/react#30813
- react/react#30812
- react/react#30811

</details>

---------

Co-authored-by: vercel-release-bot <infra+release@vercel.com>
mofeiZ added a commit that referenced this pull request Oct 11, 2024
…Tools (#30866)

This lets us track what a Component might suspend on from DevTools. We
could already collect this by replaying a component's Hooks but that
would be expensive to collect from a whole tree.

The thenables themselves might contain useful information but mainly
we'd want access to the `_debugInfo` on the thenables which might
contain additional information from the server.


https://github.com/facebook/react/blob/19bd26beb689e554fceb0b929dc5199be8cba594/packages/shared/ReactTypes.js#L114

In a follow up we should really do something similar in Flight to
transfer `use()` on the debugInfo of that Server Component.

[ghstack-poisoned]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed React Core Team Opened by a member of the React Core Team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants