Skip to content

Commit e01f988

Browse files
committed
[ci] Reduce non-deterministic builds for eslint-plugin-react-hooks (#33026)
See rollup/plugins#1425 Currently, `@babel/helper-string-parser/lib/index.js` is either emitted as a wrapped esmodule or inline depending on the ordering of async functions in `rollup/commonjs`. Specifically, `@babel/types/lib/definitions/core.js` is cyclic (i.e. transitively depends upon itself), but sometimes `@babel/helper-string-parser/lib/index.js` is emitted before this is realized. A relatively straightforward patch is to wrap all modules (see rollup/plugins#1425 (comment)). This only regresses `eslint-plugin-react-hooks` bundle size by ~1.8% and is safer (see https://github.com/rollup/plugins/blob/master/packages/commonjs/README.md#strictrequires) > The default value of true will wrap all CommonJS files in functions which are executed when they are required for the first time, preserving NodeJS semantics. This is the safest setting and should be used if the generated code does not work correctly with "auto". Note that strictRequires: true can have a small impact on the size and performance of generated code, but less so if the code is minified. (note that we're on an earlier version of `@rollup/commonjs` which does not default to `strictRequires: true`) DiffTrain build for [0c28a09](0c28a09)
1 parent a90016b commit e01f988

35 files changed

+21298
-20299
lines changed

compiled/eslint-plugin-react-hooks/index.js

Lines changed: 21212 additions & 20213 deletions
Large diffs are not rendered by default.

compiled/facebook-www/REVISION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
143d3e1b89d7f64d607bbfc844d1324b39ed93dc
1+
0c28a09eefaa0e70a313644fd8e455c8ab7ba3eb
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
143d3e1b89d7f64d607bbfc844d1324b39ed93dc
1+
0c28a09eefaa0e70a313644fd8e455c8ab7ba3eb

compiled/facebook-www/React-dev.classic.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1538,7 +1538,7 @@ __DEV__ &&
15381538
exports.useTransition = function () {
15391539
return resolveDispatcher().useTransition();
15401540
};
1541-
exports.version = "19.2.0-www-classic-143d3e1b-20250425";
1541+
exports.version = "19.2.0-www-classic-0c28a09e-20250425";
15421542
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
15431543
"function" ===
15441544
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&

compiled/facebook-www/React-dev.modern.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1538,7 +1538,7 @@ __DEV__ &&
15381538
exports.useTransition = function () {
15391539
return resolveDispatcher().useTransition();
15401540
};
1541-
exports.version = "19.2.0-www-modern-143d3e1b-20250425";
1541+
exports.version = "19.2.0-www-modern-0c28a09e-20250425";
15421542
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
15431543
"function" ===
15441544
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&

compiled/facebook-www/React-prod.classic.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -636,4 +636,4 @@ exports.useSyncExternalStore = function (
636636
exports.useTransition = function () {
637637
return ReactSharedInternals.H.useTransition();
638638
};
639-
exports.version = "19.2.0-www-classic-143d3e1b-20250425";
639+
exports.version = "19.2.0-www-classic-0c28a09e-20250425";

compiled/facebook-www/React-prod.modern.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -636,4 +636,4 @@ exports.useSyncExternalStore = function (
636636
exports.useTransition = function () {
637637
return ReactSharedInternals.H.useTransition();
638638
};
639-
exports.version = "19.2.0-www-modern-143d3e1b-20250425";
639+
exports.version = "19.2.0-www-modern-0c28a09e-20250425";

compiled/facebook-www/React-profiling.classic.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -640,7 +640,7 @@ exports.useSyncExternalStore = function (
640640
exports.useTransition = function () {
641641
return ReactSharedInternals.H.useTransition();
642642
};
643-
exports.version = "19.2.0-www-classic-143d3e1b-20250425";
643+
exports.version = "19.2.0-www-classic-0c28a09e-20250425";
644644
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
645645
"function" ===
646646
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&

compiled/facebook-www/React-profiling.modern.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -640,7 +640,7 @@ exports.useSyncExternalStore = function (
640640
exports.useTransition = function () {
641641
return ReactSharedInternals.H.useTransition();
642642
};
643-
exports.version = "19.2.0-www-modern-143d3e1b-20250425";
643+
exports.version = "19.2.0-www-modern-0c28a09e-20250425";
644644
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
645645
"function" ===
646646
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&

compiled/facebook-www/ReactART-dev.classic.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18800,10 +18800,10 @@ __DEV__ &&
1880018800
(function () {
1880118801
var internals = {
1880218802
bundleType: 1,
18803-
version: "19.2.0-www-classic-143d3e1b-20250425",
18803+
version: "19.2.0-www-classic-0c28a09e-20250425",
1880418804
rendererPackageName: "react-art",
1880518805
currentDispatcherRef: ReactSharedInternals,
18806-
reconcilerVersion: "19.2.0-www-classic-143d3e1b-20250425"
18806+
reconcilerVersion: "19.2.0-www-classic-0c28a09e-20250425"
1880718807
};
1880818808
internals.overrideHookState = overrideHookState;
1880918809
internals.overrideHookStateDeletePath = overrideHookStateDeletePath;
@@ -18837,7 +18837,7 @@ __DEV__ &&
1883718837
exports.Shape = Shape;
1883818838
exports.Surface = Surface;
1883918839
exports.Text = Text;
18840-
exports.version = "19.2.0-www-classic-143d3e1b-20250425";
18840+
exports.version = "19.2.0-www-classic-0c28a09e-20250425";
1884118841
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
1884218842
"function" ===
1884318843
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&

0 commit comments

Comments
 (0)