Skip to content

Commit

Permalink
Rename SECRET INTERNALS to `__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USE…
Browse files Browse the repository at this point in the history
…RS_THEY_CANNOT_UPGRADE` (#28789)

Follow up to #28783 and #28786.

Since we've changed the implementations of these we can rename them to
something a bit more descriptive while we're at it, since anyone
depending on them will need to upgrade their code anyway.

"react" with no condition:
`__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE`
"react" with "react-server" condition:
`__SERVER_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE`
"react-dom":
`__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE`

DiffTrain build for [f613165](f613165)
  • Loading branch information
sebmarkbage committed Apr 9, 2024
1 parent 3c7d51c commit 1c05d71
Show file tree
Hide file tree
Showing 40 changed files with 132 additions and 122 deletions.
4 changes: 2 additions & 2 deletions compiled/facebook-www/JSXDEVRuntime-dev.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ if (__DEV__) {
var React = require("react");

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; // Defensive in case this is fired before React is initialized.
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; // Defensive in case this is fired before React is initialized.

if (ReactSharedInternals != null) {
var stack = ReactSharedInternals.getStackAddendum();
Expand Down Expand Up @@ -244,7 +244,7 @@ if (__DEV__) {
}

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;

// $FlowFixMe[method-unbinding]
var hasOwnProperty = Object.prototype.hasOwnProperty;
Expand Down
4 changes: 2 additions & 2 deletions compiled/facebook-www/JSXDEVRuntime-dev.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ if (__DEV__) {
var React = require("react");

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; // Defensive in case this is fired before React is initialized.
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; // Defensive in case this is fired before React is initialized.

if (ReactSharedInternals != null) {
var stack = ReactSharedInternals.getStackAddendum();
Expand Down Expand Up @@ -244,7 +244,7 @@ if (__DEV__) {
}

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;

// $FlowFixMe[method-unbinding]
var hasOwnProperty = Object.prototype.hasOwnProperty;
Expand Down
2 changes: 1 addition & 1 deletion compiled/facebook-www/REVISION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
9644d206e8d92d0e31a9252d78933a48c62eb427
f6131653570bbbf62d642ba9343b9cd0ab1ae97c
6 changes: 3 additions & 3 deletions compiled/facebook-www/React-dev.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ if (__DEV__) {
) {
__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error());
}
var ReactVersion = "19.0.0-www-classic-16596e68";
var ReactVersion = "19.0.0-www-classic-e729f4fd";

// ATTENTION
// When adding new symbols to this file,
Expand Down Expand Up @@ -109,7 +109,7 @@ if (__DEV__) {
var React = require("react");

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; // Defensive in case this is fired before React is initialized.
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; // Defensive in case this is fired before React is initialized.

if (ReactSharedInternals != null) {
var stack = ReactSharedInternals.getStackAddendum();
Expand Down Expand Up @@ -3874,7 +3874,7 @@ if (__DEV__) {
exports.PureComponent = PureComponent;
exports.StrictMode = REACT_STRICT_MODE_TYPE;
exports.Suspense = REACT_SUSPENSE_TYPE;
exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED =
exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
ReactSharedInternals;
exports.act = act;
exports.cache = cache;
Expand Down
6 changes: 3 additions & 3 deletions compiled/facebook-www/React-dev.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ if (__DEV__) {
) {
__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error());
}
var ReactVersion = "19.0.0-www-modern-4ab6e189";
var ReactVersion = "19.0.0-www-modern-e655a09b";

// ATTENTION
// When adding new symbols to this file,
Expand Down Expand Up @@ -109,7 +109,7 @@ if (__DEV__) {
var React = require("react");

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; // Defensive in case this is fired before React is initialized.
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; // Defensive in case this is fired before React is initialized.

if (ReactSharedInternals != null) {
var stack = ReactSharedInternals.getStackAddendum();
Expand Down Expand Up @@ -3861,7 +3861,7 @@ if (__DEV__) {
exports.PureComponent = PureComponent;
exports.StrictMode = REACT_STRICT_MODE_TYPE;
exports.Suspense = REACT_SUSPENSE_TYPE;
exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED =
exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
ReactSharedInternals;
exports.act = act;
exports.cache = cache;
Expand Down
4 changes: 2 additions & 2 deletions compiled/facebook-www/React-prod.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,7 @@ exports.Profiler = REACT_PROFILER_TYPE;
exports.PureComponent = PureComponent;
exports.StrictMode = REACT_STRICT_MODE_TYPE;
exports.Suspense = REACT_SUSPENSE_TYPE;
exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED =
exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
ReactSharedInternals;
exports.act = function () {
throw Error("act(...) is not supported in production builds of React.");
Expand Down Expand Up @@ -690,4 +690,4 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.0.0-www-classic-a06f4067";
exports.version = "19.0.0-www-classic-4b82ed06";
4 changes: 2 additions & 2 deletions compiled/facebook-www/React-prod.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,7 @@ exports.Profiler = REACT_PROFILER_TYPE;
exports.PureComponent = PureComponent;
exports.StrictMode = REACT_STRICT_MODE_TYPE;
exports.Suspense = REACT_SUSPENSE_TYPE;
exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED =
exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
ReactSharedInternals;
exports.act = function () {
throw Error("act(...) is not supported in production builds of React.");
Expand Down Expand Up @@ -690,4 +690,4 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.0.0-www-modern-a06f4067";
exports.version = "19.0.0-www-modern-4b82ed06";
4 changes: 2 additions & 2 deletions compiled/facebook-www/React-profiling.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,7 @@ exports.Profiler = REACT_PROFILER_TYPE;
exports.PureComponent = PureComponent;
exports.StrictMode = REACT_STRICT_MODE_TYPE;
exports.Suspense = REACT_SUSPENSE_TYPE;
exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED =
exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
ReactSharedInternals;
exports.act = function () {
throw Error("act(...) is not supported in production builds of React.");
Expand Down Expand Up @@ -694,7 +694,7 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.0.0-www-classic-8ec1e334";
exports.version = "19.0.0-www-classic-1e341207";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
Expand Down
4 changes: 2 additions & 2 deletions compiled/facebook-www/React-profiling.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,7 @@ exports.Profiler = REACT_PROFILER_TYPE;
exports.PureComponent = PureComponent;
exports.StrictMode = REACT_STRICT_MODE_TYPE;
exports.Suspense = REACT_SUSPENSE_TYPE;
exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED =
exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
ReactSharedInternals;
exports.act = function () {
throw Error("act(...) is not supported in production builds of React.");
Expand Down Expand Up @@ -694,7 +694,7 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.0.0-www-modern-8ec1e334";
exports.version = "19.0.0-www-modern-1e341207";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
Expand Down
6 changes: 3 additions & 3 deletions compiled/facebook-www/ReactART-dev.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ if (__DEV__) {
return self;
}

var ReactVersion = "19.0.0-www-classic-8d7149a6";
var ReactVersion = "19.0.0-www-classic-8ce767ac";

var LegacyRoot = 0;
var ConcurrentRoot = 1;
Expand Down Expand Up @@ -120,7 +120,7 @@ if (__DEV__) {
var React = require("react");

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; // Defensive in case this is fired before React is initialized.
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; // Defensive in case this is fired before React is initialized.

if (ReactSharedInternals != null) {
var stack = ReactSharedInternals.getStackAddendum();
Expand Down Expand Up @@ -156,7 +156,7 @@ if (__DEV__) {
}

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;

// Re-export dynamic flags from the www version.
var dynamicFeatureFlags = require("ReactFeatureFlags");
Expand Down
6 changes: 3 additions & 3 deletions compiled/facebook-www/ReactART-dev.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ if (__DEV__) {
return self;
}

var ReactVersion = "19.0.0-www-modern-2a52e118";
var ReactVersion = "19.0.0-www-modern-070c93c4";

var LegacyRoot = 0;
var ConcurrentRoot = 1;
Expand Down Expand Up @@ -120,7 +120,7 @@ if (__DEV__) {
var React = require("react");

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; // Defensive in case this is fired before React is initialized.
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; // Defensive in case this is fired before React is initialized.

if (ReactSharedInternals != null) {
var stack = ReactSharedInternals.getStackAddendum();
Expand Down Expand Up @@ -156,7 +156,7 @@ if (__DEV__) {
}

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;

// Re-export dynamic flags from the www version.
var dynamicFeatureFlags = require("ReactFeatureFlags");
Expand Down
6 changes: 3 additions & 3 deletions compiled/facebook-www/ReactART-prod.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ function formatProdErrorMessage(code) {
);
}
var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,
dynamicFeatureFlags = require("ReactFeatureFlags"),
enableDebugTracing = dynamicFeatureFlags.enableDebugTracing,
enableLazyContextPropagation =
Expand Down Expand Up @@ -10594,7 +10594,7 @@ var slice = Array.prototype.slice,
return null;
},
bundleType: 0,
version: "19.0.0-www-classic-2cc2d08f",
version: "19.0.0-www-classic-e80018a0",
rendererPackageName: "react-art"
};
var internals$jscomp$inline_1322 = {
Expand Down Expand Up @@ -10625,7 +10625,7 @@ var internals$jscomp$inline_1322 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-www-classic-2cc2d08f"
reconcilerVersion: "19.0.0-www-classic-e80018a0"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1323 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
Expand Down
6 changes: 3 additions & 3 deletions compiled/facebook-www/ReactART-prod.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ function formatProdErrorMessage(code) {
);
}
var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,
dynamicFeatureFlags = require("ReactFeatureFlags"),
enableDebugTracing = dynamicFeatureFlags.enableDebugTracing,
enableLazyContextPropagation =
Expand Down Expand Up @@ -10073,7 +10073,7 @@ var slice = Array.prototype.slice,
return null;
},
bundleType: 0,
version: "19.0.0-www-modern-69dc4b82",
version: "19.0.0-www-modern-2ada2d66",
rendererPackageName: "react-art"
};
var internals$jscomp$inline_1307 = {
Expand Down Expand Up @@ -10104,7 +10104,7 @@ var internals$jscomp$inline_1307 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-www-modern-69dc4b82"
reconcilerVersion: "19.0.0-www-modern-2ada2d66"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1308 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
Expand Down
9 changes: 5 additions & 4 deletions compiled/facebook-www/ReactDOM-dev.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ if (__DEV__) {
var React = require("react");

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; // Defensive in case this is fired before React is initialized.
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; // Defensive in case this is fired before React is initialized.

if (ReactSharedInternals != null) {
var stack = ReactSharedInternals.getStackAddendum();
Expand Down Expand Up @@ -115,7 +115,7 @@ if (__DEV__) {
}

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;

// Re-export dynamic flags from the www version.
var dynamicFeatureFlags = require("ReactFeatureFlags");
Expand Down Expand Up @@ -36145,7 +36145,7 @@ if (__DEV__) {
return root;
}

var ReactVersion = "19.0.0-www-classic-969b8d04";
var ReactVersion = "19.0.0-www-classic-4106d899";

function createPortal$1(
children,
Expand Down Expand Up @@ -49674,7 +49674,8 @@ if (__DEV__) {
}
});

exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = Internals;
exports.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
Internals;
exports.createPortal = createPortal;
exports.createRoot = createRoot;
exports.findDOMNode = findDOMNode;
Expand Down
9 changes: 5 additions & 4 deletions compiled/facebook-www/ReactDOM-dev.modern.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ if (__DEV__) {
var React = require("react");

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; // Defensive in case this is fired before React is initialized.
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; // Defensive in case this is fired before React is initialized.

if (ReactSharedInternals != null) {
var stack = ReactSharedInternals.getStackAddendum();
Expand Down Expand Up @@ -1971,7 +1971,7 @@ if (__DEV__) {
}

var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;

var FunctionComponent = 0;
var ClassComponent = 1;
Expand Down Expand Up @@ -45641,7 +45641,7 @@ if (__DEV__) {
return root;
}

var ReactVersion = "19.0.0-www-modern-03a3c121";
var ReactVersion = "19.0.0-www-modern-d80f9f9e";

function createPortal$1(
children,
Expand Down Expand Up @@ -48194,7 +48194,8 @@ if (__DEV__) {
);
}

exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = Internals;
exports.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
Internals;
exports.createPortal = createPortal;
exports.createRoot = createRoot;
exports.flushSync = flushSync;
Expand Down
11 changes: 6 additions & 5 deletions compiled/facebook-www/ReactDOM-prod.classic.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ function formatProdErrorMessage(code) {
);
}
var ReactSharedInternals =
React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,
React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,
dynamicFeatureFlags = require("ReactFeatureFlags"),
disableIEWorkarounds = dynamicFeatureFlags.disableIEWorkarounds,
enableTrustedTypesIntegration =
Expand Down Expand Up @@ -16991,7 +16991,7 @@ Internals.Events = [
var devToolsConfig$jscomp$inline_1727 = {
findFiberByHostInstance: getClosestInstanceFromNode,
bundleType: 0,
version: "19.0.0-www-classic-6a81abec",
version: "19.0.0-www-classic-007b0a8e",
rendererPackageName: "react-dom"
};
var internals$jscomp$inline_2155 = {
Expand Down Expand Up @@ -17021,7 +17021,7 @@ var internals$jscomp$inline_2155 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-www-classic-6a81abec"
reconcilerVersion: "19.0.0-www-classic-007b0a8e"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_2156 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
Expand Down Expand Up @@ -17163,7 +17163,8 @@ assign(Internals, {
}
}
});
exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = Internals;
exports.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =
Internals;
exports.createPortal = function (children, container) {
var key =
2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : null;
Expand Down Expand Up @@ -17483,4 +17484,4 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.0.0-www-classic-6a81abec";
exports.version = "19.0.0-www-classic-007b0a8e";
Loading

0 comments on commit 1c05d71

Please sign in to comment.