Skip to content

Commit

Permalink
Remove propTypes on instance warning (#30296)
Browse files Browse the repository at this point in the history
`propTypes` are no longer supported at all in React 19, remove this
outdated warning.

DiffTrain build for commit ba95cf4.
  • Loading branch information
kassens committed Jul 9, 2024
1 parent ff1f53f commit 468daf1
Show file tree
Hide file tree
Showing 14 changed files with 41 additions and 56 deletions.
2 changes: 1 addition & 1 deletion compiled-rn/VERSION_NATIVE_FB
Original file line number Diff line number Diff line change
@@ -1 +1 @@
19.0.0-native-fb-274c980c53-20240708
19.0.0-native-fb-ba95cf4b8f-20240709
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<406a88d1a4fab2a1a30035ac1866b4c5>>
* @generated SignedSource<<6c132ca6fd0ae1732737dbd66e8dd708>>
*/

"use strict";
Expand Down Expand Up @@ -5257,11 +5257,6 @@ __DEV__ &&
"getDefaultProps was defined on %s, a plain JavaScript class. This is only supported for classes created using React.createClass. Use a static property to define defaultProps instead.",
name
);
instance.propTypes &&
error$jscomp$0(
"propTypes was defined as an instance property on %s. Use a static property to define propTypes instead.",
name
);
instance.contextType &&
error$jscomp$0(
"contextType was defined as an instance property on %s. Use a static property to define contextType instead.",
Expand Down Expand Up @@ -15080,14 +15075,14 @@ __DEV__ &&
scheduleRoot: scheduleRoot,
setRefreshHandler: setRefreshHandler,
getCurrentFiber: getCurrentFiberForDevTools,
reconcilerVersion: "19.0.0-native-fb-274c980c53-20240708"
reconcilerVersion: "19.0.0-native-fb-ba95cf4b8f-20240709"
});
})({
findFiberByHostInstance: function () {
throw Error("TestRenderer does not support findFiberByHostInstance()");
},
bundleType: 1,
version: "19.0.0-native-fb-274c980c53-20240708",
version: "19.0.0-native-fb-ba95cf4b8f-20240709",
rendererPackageName: "react-test-renderer"
});
exports._Scheduler = Scheduler;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<e5832359bed54301755c310c71ed4199>>
* @generated SignedSource<<3c1c1135c3c8e1029a66b416f4ac7abe>>
*/

"use strict";
Expand Down Expand Up @@ -9384,7 +9384,7 @@ var devToolsConfig$jscomp$inline_1053 = {
throw Error("TestRenderer does not support findFiberByHostInstance()");
},
bundleType: 0,
version: "19.0.0-native-fb-274c980c53-20240708",
version: "19.0.0-native-fb-ba95cf4b8f-20240709",
rendererPackageName: "react-test-renderer"
};
var internals$jscomp$inline_1240 = {
Expand Down Expand Up @@ -9415,7 +9415,7 @@ var internals$jscomp$inline_1240 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-native-fb-274c980c53-20240708"
reconcilerVersion: "19.0.0-native-fb-ba95cf4b8f-20240709"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1241 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<919306dbc91ada1359ea3c6b0b32c618>>
* @generated SignedSource<<82b05b96f6a5655d16111fb9f088d33b>>
*/

"use strict";
Expand Down Expand Up @@ -10004,7 +10004,7 @@ var devToolsConfig$jscomp$inline_1136 = {
throw Error("TestRenderer does not support findFiberByHostInstance()");
},
bundleType: 0,
version: "19.0.0-native-fb-274c980c53-20240708",
version: "19.0.0-native-fb-ba95cf4b8f-20240709",
rendererPackageName: "react-test-renderer"
};
(function (internals) {
Expand Down Expand Up @@ -10048,7 +10048,7 @@ var devToolsConfig$jscomp$inline_1136 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-native-fb-274c980c53-20240708"
reconcilerVersion: "19.0.0-native-fb-ba95cf4b8f-20240709"
});
exports._Scheduler = Scheduler;
exports.act = act;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<3787381ad3f2eac13a1287257e1acce9>>
* @generated SignedSource<<20bd056003409dc1c94ae24953275cb7>>
*/

"use strict";
Expand Down Expand Up @@ -1748,7 +1748,7 @@ __DEV__ &&
exports.useTransition = function () {
return resolveDispatcher().useTransition();
};
exports.version = "19.0.0-native-fb-274c980c53-20240708";
exports.version = "19.0.0-native-fb-ba95cf4b8f-20240709";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<35b776e96f5f1727760c923395a99766>>
* @generated SignedSource<<2df627fdefbe6dece12ff7a4f9919db8>>
*/

"use strict";
Expand Down Expand Up @@ -604,4 +604,4 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.0.0-native-fb-274c980c53-20240708";
exports.version = "19.0.0-native-fb-ba95cf4b8f-20240709";
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<1b02bac183a08adfa82d1581390cdd01>>
* @generated SignedSource<<726a84d1af658f5412f89c808c33c928>>
*/

"use strict";
Expand Down Expand Up @@ -608,7 +608,7 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.0.0-native-fb-274c980c53-20240708";
exports.version = "19.0.0-native-fb-ba95cf4b8f-20240709";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
274c980c535bb34e17f5d97cc22ef4dd296ab413
ba95cf4b8f39acfd7c0ccf2795a19430d35ea6b3
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<8f233b6d522b2bcef18aa23caa2b608c>>
* @generated SignedSource<<6df2be3471437a49ecb914b33f80ed32>>
*/

"use strict";
Expand Down Expand Up @@ -6260,11 +6260,6 @@ __DEV__ &&
"getDefaultProps was defined on %s, a plain JavaScript class. This is only supported for classes created using React.createClass. Use a static property to define defaultProps instead.",
name
);
instance.propTypes &&
error$jscomp$0(
"propTypes was defined as an instance property on %s. Use a static property to define propTypes instead.",
name
);
instance.contextType &&
error$jscomp$0(
"contextType was defined as an instance property on %s. Use a static property to define contextType instead.",
Expand Down Expand Up @@ -16687,12 +16682,12 @@ __DEV__ &&
scheduleRoot: scheduleRoot,
setRefreshHandler: setRefreshHandler,
getCurrentFiber: getCurrentFiberForDevTools,
reconcilerVersion: "19.0.0-native-fb-274c980c53-20240708"
reconcilerVersion: "19.0.0-native-fb-ba95cf4b8f-20240709"
});
})({
findFiberByHostInstance: getInstanceFromNode,
bundleType: 1,
version: "19.0.0-native-fb-274c980c53-20240708",
version: "19.0.0-native-fb-ba95cf4b8f-20240709",
rendererPackageName: "react-native-renderer",
rendererConfig: {
getInspectorDataForInstance: getInspectorDataForInstance,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<6f6cef3e69da66fa484d591f777702cb>>
* @generated SignedSource<<cbe2c991aec8b95d2edefd8a8e2a3086>>
*/

"use strict";
Expand Down Expand Up @@ -10601,7 +10601,7 @@ var roots = new Map(),
devToolsConfig$jscomp$inline_1136 = {
findFiberByHostInstance: getInstanceFromNode,
bundleType: 0,
version: "19.0.0-native-fb-274c980c53-20240708",
version: "19.0.0-native-fb-ba95cf4b8f-20240709",
rendererPackageName: "react-native-renderer",
rendererConfig: {
getInspectorDataForInstance: getInspectorDataForInstance,
Expand Down Expand Up @@ -10644,7 +10644,7 @@ var internals$jscomp$inline_1362 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-native-fb-274c980c53-20240708"
reconcilerVersion: "19.0.0-native-fb-ba95cf4b8f-20240709"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1363 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<08e9aaca9ad2b99e51f08d8dc61d33e4>>
* @generated SignedSource<<38b21d8355f5c93c76fbf9351cc0f7d9>>
*/

"use strict";
Expand Down Expand Up @@ -11307,7 +11307,7 @@ var roots = new Map(),
devToolsConfig$jscomp$inline_1217 = {
findFiberByHostInstance: getInstanceFromNode,
bundleType: 0,
version: "19.0.0-native-fb-274c980c53-20240708",
version: "19.0.0-native-fb-ba95cf4b8f-20240709",
rendererPackageName: "react-native-renderer",
rendererConfig: {
getInspectorDataForInstance: getInspectorDataForInstance,
Expand Down Expand Up @@ -11363,7 +11363,7 @@ var roots = new Map(),
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-native-fb-274c980c53-20240708"
reconcilerVersion: "19.0.0-native-fb-ba95cf4b8f-20240709"
});
exports.createPortal = function (children, containerTag) {
return createPortal$1(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<969999f0d202ee723f8948c461929937>>
* @generated SignedSource<<41edae2956a89d52e39bf2e7ad176508>>
*/

"use strict";
Expand Down Expand Up @@ -6206,11 +6206,6 @@ __DEV__ &&
"getDefaultProps was defined on %s, a plain JavaScript class. This is only supported for classes created using React.createClass. Use a static property to define defaultProps instead.",
name
);
instance.propTypes &&
error$jscomp$0(
"propTypes was defined as an instance property on %s. Use a static property to define propTypes instead.",
name
);
instance.contextType &&
error$jscomp$0(
"contextType was defined as an instance property on %s. Use a static property to define contextType instead.",
Expand Down Expand Up @@ -16875,11 +16870,11 @@ __DEV__ &&
var emptyObject = {};
Object.freeze(emptyObject);
var isomorphicReactPackageVersion = React.version;
if ("19.0.0-native-fb-274c980c53-20240708" !== isomorphicReactPackageVersion)
if ("19.0.0-native-fb-ba95cf4b8f-20240709" !== isomorphicReactPackageVersion)
throw Error(
'Incompatible React versions: The "react" and "react-native-renderer" packages must have the exact same version. Instead got:\n - react: ' +
(isomorphicReactPackageVersion +
"\n - react-native-renderer: 19.0.0-native-fb-274c980c53-20240708\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-native-renderer: 19.0.0-native-fb-ba95cf4b8f-20240709\nLearn more: https://react.dev/warnings/version-mismatch")
);
if (
"function" !==
Expand Down Expand Up @@ -16927,12 +16922,12 @@ __DEV__ &&
scheduleRoot: scheduleRoot,
setRefreshHandler: setRefreshHandler,
getCurrentFiber: getCurrentFiberForDevTools,
reconcilerVersion: "19.0.0-native-fb-274c980c53-20240708"
reconcilerVersion: "19.0.0-native-fb-ba95cf4b8f-20240709"
});
})({
findFiberByHostInstance: getInstanceFromTag,
bundleType: 1,
version: "19.0.0-native-fb-274c980c53-20240708",
version: "19.0.0-native-fb-ba95cf4b8f-20240709",
rendererPackageName: "react-native-renderer",
rendererConfig: {
getInspectorDataForInstance: getInspectorDataForInstance,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<22f86bde09af5f4baa1bc50a71e3ea2b>>
* @generated SignedSource<<990f855672a1c44f15981bb762196b48>>
*/

"use strict";
Expand Down Expand Up @@ -10755,11 +10755,11 @@ function traverseOwnerTreeUp(hierarchy, instance) {
traverseOwnerTreeUp(hierarchy, instance);
}
var isomorphicReactPackageVersion = React.version;
if ("19.0.0-native-fb-274c980c53-20240708" !== isomorphicReactPackageVersion)
if ("19.0.0-native-fb-ba95cf4b8f-20240709" !== isomorphicReactPackageVersion)
throw Error(
'Incompatible React versions: The "react" and "react-native-renderer" packages must have the exact same version. Instead got:\n - react: ' +
(isomorphicReactPackageVersion +
"\n - react-native-renderer: 19.0.0-native-fb-274c980c53-20240708\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-native-renderer: 19.0.0-native-fb-ba95cf4b8f-20240709\nLearn more: https://react.dev/warnings/version-mismatch")
);
if (
"function" !==
Expand Down Expand Up @@ -10809,7 +10809,7 @@ var roots = new Map(),
devToolsConfig$jscomp$inline_1210 = {
findFiberByHostInstance: getInstanceFromTag,
bundleType: 0,
version: "19.0.0-native-fb-274c980c53-20240708",
version: "19.0.0-native-fb-ba95cf4b8f-20240709",
rendererPackageName: "react-native-renderer",
rendererConfig: {
getInspectorDataForInstance: getInspectorDataForInstance,
Expand Down Expand Up @@ -10852,7 +10852,7 @@ var internals$jscomp$inline_1457 = {
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-native-fb-274c980c53-20240708"
reconcilerVersion: "19.0.0-native-fb-ba95cf4b8f-20240709"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1458 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<6194cf6db9b6afa369f5cfa3ca37b088>>
* @generated SignedSource<<2353e556cb3495b4c8ecf425042a8c05>>
*/

"use strict";
Expand Down Expand Up @@ -11462,11 +11462,11 @@ function traverseOwnerTreeUp(hierarchy, instance) {
traverseOwnerTreeUp(hierarchy, instance);
}
var isomorphicReactPackageVersion = React.version;
if ("19.0.0-native-fb-274c980c53-20240708" !== isomorphicReactPackageVersion)
if ("19.0.0-native-fb-ba95cf4b8f-20240709" !== isomorphicReactPackageVersion)
throw Error(
'Incompatible React versions: The "react" and "react-native-renderer" packages must have the exact same version. Instead got:\n - react: ' +
(isomorphicReactPackageVersion +
"\n - react-native-renderer: 19.0.0-native-fb-274c980c53-20240708\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-native-renderer: 19.0.0-native-fb-ba95cf4b8f-20240709\nLearn more: https://react.dev/warnings/version-mismatch")
);
if (
"function" !==
Expand Down Expand Up @@ -11516,7 +11516,7 @@ var roots = new Map(),
devToolsConfig$jscomp$inline_1291 = {
findFiberByHostInstance: getInstanceFromTag,
bundleType: 0,
version: "19.0.0-native-fb-274c980c53-20240708",
version: "19.0.0-native-fb-ba95cf4b8f-20240709",
rendererPackageName: "react-native-renderer",
rendererConfig: {
getInspectorDataForInstance: getInspectorDataForInstance,
Expand Down Expand Up @@ -11572,7 +11572,7 @@ var roots = new Map(),
scheduleRoot: null,
setRefreshHandler: null,
getCurrentFiber: null,
reconcilerVersion: "19.0.0-native-fb-274c980c53-20240708"
reconcilerVersion: "19.0.0-native-fb-ba95cf4b8f-20240709"
});
exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = {
computeComponentStackForErrorReporting: function (reactTag) {
Expand Down

0 comments on commit 468daf1

Please sign in to comment.