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

useFormState: Only emit markers if postback state is provided #27374

Merged
merged 1 commit into from
Sep 14, 2023

Conversation

acdlite
Copy link
Collaborator

@acdlite acdlite commented Sep 14, 2023

This is an optimization where useFormState will only emit extra comment markers if a form state is passed at the root. If no state is passed, we don't need to emit anything because none of the hooks will match.

This is an optimization where useFormState will only emit extra comment
markers if a form state is passed at the root. If no state is passed, we
don't need to emit anything because none of the hooks will match.
@facebook-github-bot facebook-github-bot added CLA Signed React Core Team Opened by a member of the React Core Team labels Sep 14, 2023
@react-sizebot
Copy link

Comparing: 54c2f2a...d0f822d

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.min.js = 166.62 kB 166.62 kB = 52.13 kB 52.13 kB
oss-experimental/react-dom/cjs/react-dom.production.min.js = 176.05 kB 176.05 kB = 54.97 kB 54.97 kB
facebook-www/ReactDOM-prod.classic.js = 571.73 kB 571.73 kB = 100.64 kB 100.64 kB
facebook-www/ReactDOM-prod.modern.js = 555.46 kB 555.46 kB = 97.75 kB 97.75 kB

Significant size changes

Includes any change greater than 0.2%:

(No significant changes)

Generated by 🚫 dangerJS against d0f822d

@acdlite acdlite merged commit d6dcad6 into facebook:main Sep 14, 2023
36 checks passed
github-actions bot pushed a commit that referenced this pull request Sep 14, 2023
This is an optimization where useFormState will only emit extra comment
markers if a form state is passed at the root. If no state is passed, we
don't need to emit anything because none of the hooks will match.

DiffTrain build for [d6dcad6](d6dcad6)
EdisonVan pushed a commit to EdisonVan/react that referenced this pull request Apr 15, 2024
…ok#27374)

This is an optimization where useFormState will only emit extra comment
markers if a form state is passed at the root. If no state is passed, we
don't need to emit anything because none of the hooks will match.
bigfootjon pushed a commit that referenced this pull request Apr 18, 2024
This is an optimization where useFormState will only emit extra comment
markers if a form state is passed at the root. If no state is passed, we
don't need to emit anything because none of the hooks will match.

DiffTrain build for commit d6dcad6.
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