Skip to content

Commit

Permalink
Avoid acccessing React internals from use-sync-external-store/shim (#…
Browse files Browse the repository at this point in the history
…29868)

Co-authored-by: eps1lon <sebastian.silbermann@vercel.com>

DiffTrain build for [50e89ec](50e89ec)
  • Loading branch information
eps1lon committed Jun 12, 2024
1 parent 8cd4109 commit bf78731
Show file tree
Hide file tree
Showing 35 changed files with 80 additions and 82 deletions.
2 changes: 1 addition & 1 deletion compiled/facebook-www/REVISION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
f3e09d6328eb0eca53d8dbc19ea6f8f4aa43db25
50e89ec9f2d44ab140e771e585226f7771da9652
2 changes: 1 addition & 1 deletion compiled/facebook-www/REVISION_TRANSFORMS
Original file line number Diff line number Diff line change
@@ -1 +1 @@
f3e09d6328eb0eca53d8dbc19ea6f8f4aa43db25
50e89ec9f2d44ab140e771e585226f7771da9652
2 changes: 1 addition & 1 deletion compiled/facebook-www/React-dev.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -1987,7 +1987,7 @@ __DEV__ &&
exports.useTransition = function () {
return resolveDispatcher().useTransition();
};
exports.version = "19.0.0-www-classic-f3e09d6328-20240612";
exports.version = "19.0.0-www-classic-50e89ec9f2-20240612";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
Expand Down
2 changes: 1 addition & 1 deletion compiled/facebook-www/React-dev.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -1967,7 +1967,7 @@ __DEV__ &&
exports.useTransition = function () {
return resolveDispatcher().useTransition();
};
exports.version = "19.0.0-www-modern-f3e09d6328-20240612";
exports.version = "19.0.0-www-modern-50e89ec9f2-20240612";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
Expand Down
2 changes: 1 addition & 1 deletion compiled/facebook-www/React-prod.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -665,4 +665,4 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.0.0-www-classic-f3e09d6328-20240612";
exports.version = "19.0.0-www-classic-50e89ec9f2-20240612";
2 changes: 1 addition & 1 deletion compiled/facebook-www/React-prod.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -665,4 +665,4 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.0.0-www-modern-f3e09d6328-20240612";
exports.version = "19.0.0-www-modern-50e89ec9f2-20240612";
2 changes: 1 addition & 1 deletion compiled/facebook-www/React-profiling.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -669,7 +669,7 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.0.0-www-classic-f3e09d6328-20240612";
exports.version = "19.0.0-www-classic-50e89ec9f2-20240612";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
Expand Down
2 changes: 1 addition & 1 deletion compiled/facebook-www/React-profiling.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -669,7 +669,7 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.0.0-www-modern-f3e09d6328-20240612";
exports.version = "19.0.0-www-modern-50e89ec9f2-20240612";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
Expand Down
4 changes: 2 additions & 2 deletions compiled/facebook-www/ReactART-dev.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -16934,14 +16934,14 @@ __DEV__ &&
scheduleRoot: scheduleRoot,
setRefreshHandler: setRefreshHandler,
getCurrentFiber: getCurrentFiberForDevTools,
reconcilerVersion: "19.0.0-www-classic-f3e09d6328-20240612"
reconcilerVersion: "19.0.0-www-classic-50e89ec9f2-20240612"
});
})({
findFiberByHostInstance: function () {
return null;
},
bundleType: 1,
version: "19.0.0-www-classic-f3e09d6328-20240612",
version: "19.0.0-www-classic-50e89ec9f2-20240612",
rendererPackageName: "react-art"
});
var ClippingRectangle = TYPES.CLIPPING_RECTANGLE,
Expand Down
4 changes: 2 additions & 2 deletions compiled/facebook-www/ReactART-dev.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -16364,14 +16364,14 @@ __DEV__ &&
scheduleRoot: scheduleRoot,
setRefreshHandler: setRefreshHandler,
getCurrentFiber: getCurrentFiberForDevTools,
reconcilerVersion: "19.0.0-www-modern-f3e09d6328-20240612"
reconcilerVersion: "19.0.0-www-modern-50e89ec9f2-20240612"
});
})({
findFiberByHostInstance: function () {
return null;
},
bundleType: 1,
version: "19.0.0-www-modern-f3e09d6328-20240612",
version: "19.0.0-www-modern-50e89ec9f2-20240612",
rendererPackageName: "react-art"
});
var ClippingRectangle = TYPES.CLIPPING_RECTANGLE,
Expand Down
4 changes: 2 additions & 2 deletions compiled/facebook-www/ReactART-prod.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -10709,7 +10709,7 @@ var slice = Array.prototype.slice,
return null;
},
bundleType: 0,
version: "19.0.0-www-classic-f3e09d6328-20240612",
version: "19.0.0-www-classic-50e89ec9f2-20240612",
rendererPackageName: "react-art"
};
var internals$jscomp$inline_1386 = {
Expand Down Expand Up @@ -10740,7 +10740,7 @@ var internals$jscomp$inline_1386 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-www-classic-f3e09d6328-20240612"
reconcilerVersion: "19.0.0-www-classic-50e89ec9f2-20240612"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1387 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
Expand Down
4 changes: 2 additions & 2 deletions compiled/facebook-www/ReactART-prod.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -10162,7 +10162,7 @@ var slice = Array.prototype.slice,
return null;
},
bundleType: 0,
version: "19.0.0-www-modern-f3e09d6328-20240612",
version: "19.0.0-www-modern-50e89ec9f2-20240612",
rendererPackageName: "react-art"
};
var internals$jscomp$inline_1372 = {
Expand Down Expand Up @@ -10193,7 +10193,7 @@ var internals$jscomp$inline_1372 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-www-modern-f3e09d6328-20240612"
reconcilerVersion: "19.0.0-www-modern-50e89ec9f2-20240612"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1373 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
Expand Down
10 changes: 5 additions & 5 deletions compiled/facebook-www/ReactDOM-dev.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -27350,11 +27350,11 @@ __DEV__ &&
: flushSyncErrorInBuildsThatSupportLegacyMode;
(function () {
var isomorphicReactPackageVersion = React.version;
if ("19.0.0-www-classic-f3e09d6328-20240612" !== isomorphicReactPackageVersion)
if ("19.0.0-www-classic-50e89ec9f2-20240612" !== isomorphicReactPackageVersion)
throw Error(
'Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:\n - react: ' +
(isomorphicReactPackageVersion +
"\n - react-dom: 19.0.0-www-classic-f3e09d6328-20240612\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-dom: 19.0.0-www-classic-50e89ec9f2-20240612\nLearn more: https://react.dev/warnings/version-mismatch")
);
})();
("function" === typeof Map &&
Expand Down Expand Up @@ -27420,12 +27420,12 @@ __DEV__ &&
scheduleRoot: scheduleRoot,
setRefreshHandler: setRefreshHandler,
getCurrentFiber: getCurrentFiberForDevTools,
reconcilerVersion: "19.0.0-www-classic-f3e09d6328-20240612"
reconcilerVersion: "19.0.0-www-classic-50e89ec9f2-20240612"
});
})({
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 1,
version: "19.0.0-www-classic-f3e09d6328-20240612",
version: "19.0.0-www-classic-50e89ec9f2-20240612",
rendererPackageName: "react-dom"
}) &&
canUseDOM &&
Expand Down Expand Up @@ -28068,7 +28068,7 @@ __DEV__ &&
exports.useFormStatus = function () {
return resolveDispatcher().useHostTransitionStatus();
};
exports.version = "19.0.0-www-classic-f3e09d6328-20240612";
exports.version = "19.0.0-www-classic-50e89ec9f2-20240612";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
Expand Down
10 changes: 5 additions & 5 deletions compiled/facebook-www/ReactDOM-dev.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -26497,11 +26497,11 @@ __DEV__ &&
return_targetInst = null;
(function () {
var isomorphicReactPackageVersion = React.version;
if ("19.0.0-www-modern-f3e09d6328-20240612" !== isomorphicReactPackageVersion)
if ("19.0.0-www-modern-50e89ec9f2-20240612" !== isomorphicReactPackageVersion)
throw Error(
'Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:\n - react: ' +
(isomorphicReactPackageVersion +
"\n - react-dom: 19.0.0-www-modern-f3e09d6328-20240612\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-dom: 19.0.0-www-modern-50e89ec9f2-20240612\nLearn more: https://react.dev/warnings/version-mismatch")
);
})();
("function" === typeof Map &&
Expand Down Expand Up @@ -26566,12 +26566,12 @@ __DEV__ &&
scheduleRoot: scheduleRoot,
setRefreshHandler: setRefreshHandler,
getCurrentFiber: getCurrentFiberForDevTools,
reconcilerVersion: "19.0.0-www-modern-f3e09d6328-20240612"
reconcilerVersion: "19.0.0-www-modern-50e89ec9f2-20240612"
});
})({
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 1,
version: "19.0.0-www-modern-f3e09d6328-20240612",
version: "19.0.0-www-modern-50e89ec9f2-20240612",
rendererPackageName: "react-dom"
}) &&
canUseDOM &&
Expand Down Expand Up @@ -27167,7 +27167,7 @@ __DEV__ &&
exports.useFormStatus = function () {
return resolveDispatcher().useHostTransitionStatus();
};
exports.version = "19.0.0-www-modern-f3e09d6328-20240612";
exports.version = "19.0.0-www-modern-50e89ec9f2-20240612";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
Expand Down
10 changes: 5 additions & 5 deletions compiled/facebook-www/ReactDOM-prod.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -17149,14 +17149,14 @@ function getCrossOriginStringAs(as, input) {
}
var isomorphicReactPackageVersion$jscomp$inline_1769 = React.version;
if (
"19.0.0-www-classic-f3e09d6328-20240612" !==
"19.0.0-www-classic-50e89ec9f2-20240612" !==
isomorphicReactPackageVersion$jscomp$inline_1769
)
throw Error(
formatProdErrorMessage(
527,
isomorphicReactPackageVersion$jscomp$inline_1769,
"19.0.0-www-classic-f3e09d6328-20240612"
"19.0.0-www-classic-50e89ec9f2-20240612"
)
);
function flushSyncFromReconciler(fn) {
Expand Down Expand Up @@ -17202,7 +17202,7 @@ Internals.Events = [
var devToolsConfig$jscomp$inline_1776 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "19.0.0-www-classic-f3e09d6328-20240612",
version: "19.0.0-www-classic-50e89ec9f2-20240612",
rendererPackageName: "react-dom"
};
var internals$jscomp$inline_2220 = {
Expand Down Expand Up @@ -17232,7 +17232,7 @@ var internals$jscomp$inline_2220 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-www-classic-f3e09d6328-20240612"
reconcilerVersion: "19.0.0-www-classic-50e89ec9f2-20240612"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_2221 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
Expand Down Expand Up @@ -17696,4 +17696,4 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.0.0-www-classic-f3e09d6328-20240612";
exports.version = "19.0.0-www-classic-50e89ec9f2-20240612";
10 changes: 5 additions & 5 deletions compiled/facebook-www/ReactDOM-prod.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -16464,14 +16464,14 @@ function getCrossOriginStringAs(as, input) {
}
var isomorphicReactPackageVersion$jscomp$inline_1740 = React.version;
if (
"19.0.0-www-modern-f3e09d6328-20240612" !==
"19.0.0-www-modern-50e89ec9f2-20240612" !==
isomorphicReactPackageVersion$jscomp$inline_1740
)
throw Error(
formatProdErrorMessage(
527,
isomorphicReactPackageVersion$jscomp$inline_1740,
"19.0.0-www-modern-f3e09d6328-20240612"
"19.0.0-www-modern-50e89ec9f2-20240612"
)
);
Internals.findDOMNode = function (componentOrElement) {
Expand All @@ -16490,7 +16490,7 @@ Internals.Events = [
var devToolsConfig$jscomp$inline_1742 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "19.0.0-www-modern-f3e09d6328-20240612",
version: "19.0.0-www-modern-50e89ec9f2-20240612",
rendererPackageName: "react-dom"
};
var internals$jscomp$inline_2211 = {
Expand Down Expand Up @@ -16520,7 +16520,7 @@ var internals$jscomp$inline_2211 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-www-modern-f3e09d6328-20240612"
reconcilerVersion: "19.0.0-www-modern-50e89ec9f2-20240612"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_2212 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
Expand Down Expand Up @@ -16891,4 +16891,4 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.0.0-www-modern-f3e09d6328-20240612";
exports.version = "19.0.0-www-modern-50e89ec9f2-20240612";
10 changes: 5 additions & 5 deletions compiled/facebook-www/ReactDOM-profiling.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -17916,14 +17916,14 @@ function getCrossOriginStringAs(as, input) {
}
var isomorphicReactPackageVersion$jscomp$inline_1856 = React.version;
if (
"19.0.0-www-classic-f3e09d6328-20240612" !==
"19.0.0-www-classic-50e89ec9f2-20240612" !==
isomorphicReactPackageVersion$jscomp$inline_1856
)
throw Error(
formatProdErrorMessage(
527,
isomorphicReactPackageVersion$jscomp$inline_1856,
"19.0.0-www-classic-f3e09d6328-20240612"
"19.0.0-www-classic-50e89ec9f2-20240612"
)
);
function flushSyncFromReconciler(fn) {
Expand Down Expand Up @@ -17969,7 +17969,7 @@ Internals.Events = [
var devToolsConfig$jscomp$inline_1863 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "19.0.0-www-classic-f3e09d6328-20240612",
version: "19.0.0-www-classic-50e89ec9f2-20240612",
rendererPackageName: "react-dom"
};
(function (internals) {
Expand Down Expand Up @@ -18013,7 +18013,7 @@ var devToolsConfig$jscomp$inline_1863 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-www-classic-f3e09d6328-20240612"
reconcilerVersion: "19.0.0-www-classic-50e89ec9f2-20240612"
});
function ReactDOMRoot(internalRoot) {
this._internalRoot = internalRoot;
Expand Down Expand Up @@ -18464,7 +18464,7 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.0.0-www-classic-f3e09d6328-20240612";
exports.version = "19.0.0-www-classic-50e89ec9f2-20240612";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
Expand Down
10 changes: 5 additions & 5 deletions compiled/facebook-www/ReactDOM-profiling.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -17214,14 +17214,14 @@ function getCrossOriginStringAs(as, input) {
}
var isomorphicReactPackageVersion$jscomp$inline_1827 = React.version;
if (
"19.0.0-www-modern-f3e09d6328-20240612" !==
"19.0.0-www-modern-50e89ec9f2-20240612" !==
isomorphicReactPackageVersion$jscomp$inline_1827
)
throw Error(
formatProdErrorMessage(
527,
isomorphicReactPackageVersion$jscomp$inline_1827,
"19.0.0-www-modern-f3e09d6328-20240612"
"19.0.0-www-modern-50e89ec9f2-20240612"
)
);
Internals.findDOMNode = function (componentOrElement) {
Expand All @@ -17240,7 +17240,7 @@ Internals.Events = [
var devToolsConfig$jscomp$inline_1829 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "19.0.0-www-modern-f3e09d6328-20240612",
version: "19.0.0-www-modern-50e89ec9f2-20240612",
rendererPackageName: "react-dom"
};
(function (internals) {
Expand Down Expand Up @@ -17284,7 +17284,7 @@ var devToolsConfig$jscomp$inline_1829 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-www-modern-f3e09d6328-20240612"
reconcilerVersion: "19.0.0-www-modern-50e89ec9f2-20240612"
});
function ReactDOMRoot(internalRoot) {
this._internalRoot = internalRoot;
Expand Down Expand Up @@ -17642,7 +17642,7 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.0.0-www-modern-f3e09d6328-20240612";
exports.version = "19.0.0-www-modern-50e89ec9f2-20240612";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
Expand Down
2 changes: 1 addition & 1 deletion compiled/facebook-www/ReactDOMServer-dev.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -8721,5 +8721,5 @@ __DEV__ &&
'The server used "renderToString" which does not support Suspense. If you intended for this Suspense boundary to render the fallback content on the server consider throwing an Error somewhere within the Suspense boundary. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server'
);
};
exports.version = "19.0.0-www-classic-f3e09d6328-20240612";
exports.version = "19.0.0-www-classic-50e89ec9f2-20240612";
})();
2 changes: 1 addition & 1 deletion compiled/facebook-www/ReactDOMServer-dev.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -8677,5 +8677,5 @@ __DEV__ &&
'The server used "renderToString" which does not support Suspense. If you intended for this Suspense boundary to render the fallback content on the server consider throwing an Error somewhere within the Suspense boundary. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server'
);
};
exports.version = "19.0.0-www-modern-f3e09d6328-20240612";
exports.version = "19.0.0-www-modern-50e89ec9f2-20240612";
})();
2 changes: 1 addition & 1 deletion compiled/facebook-www/ReactDOMServer-prod.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -5719,4 +5719,4 @@ exports.renderToString = function (children, options) {
'The server used "renderToString" which does not support Suspense. If you intended for this Suspense boundary to render the fallback content on the server consider throwing an Error somewhere within the Suspense boundary. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server'
);
};
exports.version = "19.0.0-www-classic-f3e09d6328-20240612";
exports.version = "19.0.0-www-classic-50e89ec9f2-20240612";
2 changes: 1 addition & 1 deletion compiled/facebook-www/ReactDOMServer-prod.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -5697,4 +5697,4 @@ exports.renderToString = function (children, options) {
'The server used "renderToString" which does not support Suspense. If you intended for this Suspense boundary to render the fallback content on the server consider throwing an Error somewhere within the Suspense boundary. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server'
);
};
exports.version = "19.0.0-www-modern-f3e09d6328-20240612";
exports.version = "19.0.0-www-modern-50e89ec9f2-20240612";
Loading

0 comments on commit bf78731

Please sign in to comment.