Skip to content
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

[Fizz] Add Owner Stacks when render is aborted #32735

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

eps1lon
Copy link
Collaborator

@eps1lon eps1lon commented Mar 25, 2025

Summary

captureOwnerStack now returns the corresponding owner stack to the parent stack when we abort a Fizz render.

How did you test this change?

  • added test (initial commit has current behavior)

@eps1lon eps1lon changed the title Sebbie/fizz abort ownerstack [Fizz] Add Owner Stacks when render is aborted Mar 25, 2025
@github-actions github-actions bot added the React Core Team Opened by a member of the React Core Team label Mar 25, 2025
@react-sizebot
Copy link

react-sizebot commented Mar 25, 2025

Comparing: b59f186...8c0c76a

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 = 1.83 kB 1.83 kB
oss-stable/react-dom/cjs/react-dom-client.production.js = 515.14 kB 515.14 kB = 91.74 kB 91.74 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 = 614.35 kB 614.35 kB = 108.76 kB 108.76 kB
facebook-www/ReactDOM-prod.classic.js = 650.34 kB 650.34 kB = 114.79 kB 114.79 kB
facebook-www/ReactDOM-prod.modern.js = 640.62 kB 640.62 kB = 113.23 kB 113.23 kB

Significant size changes

Includes any change greater than 0.2%:

Expand to show
Name +/- Base Current +/- gzip Base gzip Current gzip
oss-stable-semver/react-server/cjs/react-server.development.js +0.26% 171.74 kB 172.18 kB +0.20% 30.89 kB 30.96 kB
oss-stable/react-server/cjs/react-server.development.js +0.26% 171.74 kB 172.18 kB +0.20% 30.89 kB 30.96 kB
oss-experimental/react-server/cjs/react-server.development.js +0.23% 188.73 kB 189.17 kB +0.19% 32.99 kB 33.05 kB
oss-experimental/react-noop-renderer/cjs/react-noop-renderer-server.development.js +0.22% 7.31 kB 7.32 kB +0.06% 1.59 kB 1.59 kB
oss-stable-semver/react-noop-renderer/cjs/react-noop-renderer-server.development.js +0.22% 7.31 kB 7.32 kB +0.06% 1.59 kB 1.59 kB
oss-stable/react-noop-renderer/cjs/react-noop-renderer-server.development.js +0.22% 7.31 kB 7.32 kB +0.06% 1.59 kB 1.59 kB

Generated by 🚫 dangerJS against 8c0c76a

@eps1lon eps1lon force-pushed the sebbie/fizz-abort-ownerstack branch from 404c603 to 8c0c76a Compare March 25, 2025 05:19
@@ -311,6 +311,7 @@ function render(children: React$Element<any>, options?: Options): Destination {
children,
null,
null,
null,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Otherwise the optional on* callbacks were not lined up correctly.

'\n in Component (at **)' + '\n in App (at **)',
);
expect(normalizeCodeLocInfo(ownerStack)).toEqual(
__DEV__ ? '\n in App (at **)' : null,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ideally, the stack would start at Component

@eps1lon eps1lon marked this pull request as ready for review March 25, 2025 05:32
@eps1lon eps1lon requested a review from sebmarkbage March 25, 2025 05:32
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.

3 participants