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

Override .bind on Server References on the Client #27282

Merged
merged 1 commit into from
Aug 26, 2023

Conversation

sebmarkbage
Copy link
Collaborator

That way when you bind arguments to a Server Reference, it's still a server reference and works with progressive enhancement.

This already works on the Server (RSC) layer.

@sebmarkbage sebmarkbage requested a review from acdlite August 25, 2023 19:13
@facebook-github-bot facebook-github-bot added CLA Signed React Core Team Opened by a member of the React Core Team labels Aug 25, 2023
@react-sizebot
Copy link

react-sizebot commented Aug 25, 2023

Comparing: ab31a9e...e945988

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 = 165.61 kB 165.61 kB = 51.87 kB 51.88 kB
oss-experimental/react-dom/cjs/react-dom.production.min.js = 173.44 kB 173.44 kB = 54.24 kB 54.25 kB
facebook-www/ReactDOM-prod.classic.js = 569.80 kB 569.80 kB = 100.39 kB 100.39 kB
facebook-www/ReactDOM-prod.modern.js = 553.60 kB 553.60 kB = 97.54 kB 97.54 kB
oss-stable-semver/react-client/cjs/react-client-flight.production.min.js +3.97% 9.15 kB 9.51 kB +3.39% 3.60 kB 3.73 kB
oss-stable/react-client/cjs/react-client-flight.production.min.js +3.97% 9.15 kB 9.51 kB +3.39% 3.60 kB 3.73 kB
oss-experimental/react-client/cjs/react-client-flight.production.min.js +3.51% 10.34 kB 10.70 kB +2.97% 3.94 kB 4.05 kB
oss-stable-semver/react-server-dom-esm/cjs/react-server-dom-esm-client.node.production.min.js +3.31% 10.31 kB 10.65 kB +2.90% 4.00 kB 4.11 kB
oss-stable/react-server-dom-esm/cjs/react-server-dom-esm-client.node.production.min.js +3.31% 10.31 kB 10.65 kB +2.90% 4.00 kB 4.11 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.production.min.js +3.19% 10.71 kB 11.05 kB +2.79% 4.16 kB 4.28 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.production.min.js +3.19% 10.71 kB 11.05 kB +2.79% 4.16 kB 4.28 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.production.min.js +3.09% 11.03 kB 11.37 kB +2.82% 4.29 kB 4.41 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.production.min.js +3.09% 11.03 kB 11.37 kB +2.82% 4.29 kB 4.41 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.production.min.js +3.02% 11.29 kB 11.63 kB +2.78% 4.38 kB 4.50 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.production.min.js +3.02% 11.29 kB 11.63 kB +2.78% 4.38 kB 4.50 kB
oss-experimental/react-server-dom-esm/cjs/react-server-dom-esm-client.node.production.min.js +2.93% 11.63 kB 11.98 kB +2.75% 4.37 kB 4.49 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.production.min.js +2.83% 12.04 kB 12.38 kB +2.62% 4.54 kB 4.65 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.production.min.js +2.76% 12.36 kB 12.70 kB +2.61% 4.67 kB 4.79 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.production.min.js +2.70% 12.61 kB 12.95 kB +2.63% 4.75 kB 4.88 kB
oss-stable-semver/react-client/cjs/react-client-flight.development.js +2.14% 48.41 kB 49.45 kB +1.91% 12.12 kB 12.35 kB
oss-stable/react-client/cjs/react-client-flight.development.js +2.14% 48.41 kB 49.45 kB +1.91% 12.12 kB 12.35 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-client/cjs/react-client-flight.production.min.js +3.97% 9.15 kB 9.51 kB +3.39% 3.60 kB 3.73 kB
oss-stable/react-client/cjs/react-client-flight.production.min.js +3.97% 9.15 kB 9.51 kB +3.39% 3.60 kB 3.73 kB
oss-experimental/react-client/cjs/react-client-flight.production.min.js +3.51% 10.34 kB 10.70 kB +2.97% 3.94 kB 4.05 kB
oss-stable-semver/react-server-dom-esm/cjs/react-server-dom-esm-client.node.production.min.js +3.31% 10.31 kB 10.65 kB +2.90% 4.00 kB 4.11 kB
oss-stable/react-server-dom-esm/cjs/react-server-dom-esm-client.node.production.min.js +3.31% 10.31 kB 10.65 kB +2.90% 4.00 kB 4.11 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.production.min.js +3.19% 10.71 kB 11.05 kB +2.79% 4.16 kB 4.28 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.production.min.js +3.19% 10.71 kB 11.05 kB +2.79% 4.16 kB 4.28 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.production.min.js +3.09% 11.03 kB 11.37 kB +2.82% 4.29 kB 4.41 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.production.min.js +3.09% 11.03 kB 11.37 kB +2.82% 4.29 kB 4.41 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.production.min.js +3.02% 11.29 kB 11.63 kB +2.78% 4.38 kB 4.50 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.production.min.js +3.02% 11.29 kB 11.63 kB +2.78% 4.38 kB 4.50 kB
oss-experimental/react-server-dom-esm/cjs/react-server-dom-esm-client.node.production.min.js +2.93% 11.63 kB 11.98 kB +2.75% 4.37 kB 4.49 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.production.min.js +2.83% 12.04 kB 12.38 kB +2.62% 4.54 kB 4.65 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.production.min.js +2.76% 12.36 kB 12.70 kB +2.61% 4.67 kB 4.79 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.production.min.js +2.70% 12.61 kB 12.95 kB +2.63% 4.75 kB 4.88 kB
oss-stable-semver/react-client/cjs/react-client-flight.development.js +2.14% 48.41 kB 49.45 kB +1.91% 12.12 kB 12.35 kB
oss-stable/react-client/cjs/react-client-flight.development.js +2.14% 48.41 kB 49.45 kB +1.91% 12.12 kB 12.35 kB
oss-experimental/react-client/cjs/react-client-flight.development.js +1.94% 53.46 kB 54.49 kB +1.86% 13.13 kB 13.38 kB
oss-stable-semver/react-server-dom-esm/cjs/react-server-dom-esm-client.node.development.js +1.65% 52.18 kB 53.04 kB +1.77% 12.66 kB 12.88 kB
oss-stable/react-server-dom-esm/cjs/react-server-dom-esm-client.node.development.js +1.65% 52.18 kB 53.04 kB +1.77% 12.66 kB 12.88 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.development.js +1.61% 53.47 kB 54.33 kB +1.76% 12.98 kB 13.21 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.development.js +1.61% 53.47 kB 54.33 kB +1.76% 12.98 kB 13.21 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.development.js +1.57% 54.71 kB 55.57 kB +1.76% 13.37 kB 13.60 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.development.js +1.57% 54.71 kB 55.57 kB +1.76% 13.37 kB 13.60 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.development.js +1.55% 55.43 kB 56.29 kB +1.72% 13.52 kB 13.75 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.development.js +1.55% 55.43 kB 56.29 kB +1.72% 13.52 kB 13.75 kB
oss-experimental/react-server-dom-esm/cjs/react-server-dom-esm-client.node.development.js +1.50% 57.23 kB 58.09 kB +1.65% 13.68 kB 13.91 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.development.js +1.47% 58.51 kB 59.37 kB +1.62% 14.00 kB 14.23 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.development.js +1.44% 59.75 kB 60.61 kB +1.63% 14.39 kB 14.62 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.development.js +1.42% 60.48 kB 61.34 kB +1.59% 14.54 kB 14.77 kB
oss-stable-semver/react-server-dom-esm/cjs/react-server-dom-esm-client.browser.production.min.js +0.22% 9.66 kB 9.68 kB +0.24% 3.75 kB 3.76 kB
oss-stable/react-server-dom-esm/cjs/react-server-dom-esm-client.browser.production.min.js +0.22% 9.66 kB 9.68 kB +0.24% 3.75 kB 3.76 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.production.min.js +0.20% 10.36 kB 10.38 kB +0.17% 4.04 kB 4.04 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.production.min.js +0.20% 10.36 kB 10.38 kB +0.17% 4.04 kB 4.04 kB

Generated by 🚫 dangerJS against e945988

That way when you bind arguments to a Server Reference, it's still a server
reference and works with progressive enhancement.

This already works on the Server (RSC) layer.
@sebmarkbage sebmarkbage merged commit b798223 into facebook:main Aug 26, 2023
EdisonVan pushed a commit to EdisonVan/react that referenced this pull request Apr 15, 2024
That way when you bind arguments to a Server Reference, it's still a
server reference and works with progressive enhancement.

This already works on the Server (RSC) layer.
bigfootjon pushed a commit that referenced this pull request Apr 18, 2024
That way when you bind arguments to a Server Reference, it's still a
server reference and works with progressive enhancement.

This already works on the Server (RSC) layer.

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