Skip to content

Conversation

eps1lon
Copy link
Collaborator

@eps1lon eps1lon commented Sep 17, 2025

Stacked on #34514

Usage of Buffer was introduced in #21641

Since then atob is widely available in browsers (and workers). Node.js 16 also has it even though there's currently no Node.js target in DevTools (Flight renderer is only supported in the browser).

The other usage of Buffer was in the transitive dependency jsesc which was caught by our e2e tests. A modern version of jsesc is now used which checks if Buffer exists first via typeof Buffer.

@meta-cla meta-cla bot added the CLA Signed label Sep 17, 2025
@github-actions github-actions bot added the React Core Team Opened by a member of the React Core Team label Sep 17, 2025
@eps1lon eps1lon changed the title [DevTools] Minify backend [DevTools] Stop polyfilling Buffer Sep 17, 2025
Comment on lines +13 to +17
"@babel/parser": "^7.28.3",
"@babel/preset-env": "7.26.9",
"@babel/preset-flow": "^7.10.4",
"@babel/runtime": "^7.11.2",
"@babel/traverse": "^7.12.5",
"@babel/traverse": "^7.28.3",
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@react-sizebot
Copy link

react-sizebot commented Sep 17, 2025

Comparing: 6a4c8f5...552869b

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.83 kB 1.83 kB
oss-stable/react-dom/cjs/react-dom-client.production.js = 534.32 kB 534.32 kB = 94.32 kB 94.33 kB
oss-experimental/react-dom/cjs/react-dom.production.js = 6.69 kB 6.69 kB +0.05% 1.83 kB 1.83 kB
oss-experimental/react-dom/cjs/react-dom-client.production.js = 663.64 kB 663.64 kB = 117.01 kB 117.01 kB
facebook-www/ReactDOM-prod.classic.js = 687.59 kB 687.59 kB = 121.04 kB 121.04 kB
facebook-www/ReactDOM-prod.modern.js = 678.02 kB 678.02 kB = 119.39 kB 119.39 kB

Significant size changes

Includes any change greater than 0.2%:

(No significant changes)

Generated by 🚫 dangerJS against 552869b

@eps1lon eps1lon force-pushed the sebbie/09-17-_devtools_stop_polyfilling_buffer_ branch 3 times, most recently from 2742e09 to 290438f Compare September 17, 2025 09:35
@eps1lon eps1lon changed the title [DevTools] Stop polyfilling Buffer [DevTools] Stop polyfilling Buffer Sep 17, 2025
@eps1lon eps1lon requested a review from hoxyq September 17, 2025 09:46
@eps1lon eps1lon marked this pull request as ready for review September 17, 2025 09:46
@eps1lon eps1lon force-pushed the sebbie/09-17-_devtools_stop_polyfilling_buffer_ branch from 290438f to 552869b Compare September 17, 2025 13:04
@eps1lon eps1lon merged commit 81d6692 into facebook:main Sep 17, 2025
241 checks passed
@eps1lon eps1lon deleted the sebbie/09-17-_devtools_stop_polyfilling_buffer_ branch September 17, 2025 13:46
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