Skip to content

Commit 2579855

Browse files
committed
Combine createElement and JSX modules (#28320)
Depends on: - #28317 --- There's a ton of overlap between the createElement implementation and the JSX implementation, so I combined them into a single module. In the actual build output, the shared code between JSX and createElement will get duplicated anyway, because react/jsx-runtime and react (where createElement lives) are separate, flat build artifacts. So this is more about code organization — with a few key exceptions, the implementations of createElement and jsx are highly coupled. DiffTrain build for commit 5fb2c93.
1 parent 163b2f0 commit 2579855

File tree

9 files changed

+2289
-2729
lines changed

9 files changed

+2289
-2729
lines changed

compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-dev.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -25686,7 +25686,7 @@ if (__DEV__) {
2568625686
return root;
2568725687
}
2568825688

25689-
var ReactVersion = "18.3.0-canary-ec160f32c-20240219";
25689+
var ReactVersion = "18.3.0-canary-5fb2c93f3-20240219";
2569025690

2569125691
// Might add PROFILE later.
2569225692

compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-prod.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -9176,7 +9176,7 @@ var devToolsConfig$jscomp$inline_1014 = {
91769176
throw Error("TestRenderer does not support findFiberByHostInstance()");
91779177
},
91789178
bundleType: 0,
9179-
version: "18.3.0-canary-ec160f32c-20240219",
9179+
version: "18.3.0-canary-5fb2c93f3-20240219",
91809180
rendererPackageName: "react-test-renderer"
91819181
};
91829182
var internals$jscomp$inline_1195 = {
@@ -9207,7 +9207,7 @@ var internals$jscomp$inline_1195 = {
92079207
scheduleRoot: null,
92089208
setRefreshHandler: null,
92099209
getCurrentFiber: null,
9210-
reconcilerVersion: "18.3.0-canary-ec160f32c-20240219"
9210+
reconcilerVersion: "18.3.0-canary-5fb2c93f3-20240219"
92119211
};
92129212
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
92139213
var hook$jscomp$inline_1196 = __REACT_DEVTOOLS_GLOBAL_HOOK__;

compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-profiling.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -9604,7 +9604,7 @@ var devToolsConfig$jscomp$inline_1056 = {
96049604
throw Error("TestRenderer does not support findFiberByHostInstance()");
96059605
},
96069606
bundleType: 0,
9607-
version: "18.3.0-canary-ec160f32c-20240219",
9607+
version: "18.3.0-canary-5fb2c93f3-20240219",
96089608
rendererPackageName: "react-test-renderer"
96099609
};
96109610
var internals$jscomp$inline_1236 = {
@@ -9635,7 +9635,7 @@ var internals$jscomp$inline_1236 = {
96359635
scheduleRoot: null,
96369636
setRefreshHandler: null,
96379637
getCurrentFiber: null,
9638-
reconcilerVersion: "18.3.0-canary-ec160f32c-20240219"
9638+
reconcilerVersion: "18.3.0-canary-5fb2c93f3-20240219"
96399639
};
96409640
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
96419641
var hook$jscomp$inline_1237 = __REACT_DEVTOOLS_GLOBAL_HOOK__;

compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXDEVRuntime-dev.js

+6-8
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* @noflow
88
* @nolint
99
* @preventMunge
10-
* @generated SignedSource<<dcd2c20e1a26861ff0f60d651a2f6e93>>
10+
* @generated SignedSource<<9d1803d74418a7ac44bc89ae8cd0f170>>
1111
*/
1212

1313
"use strict";
@@ -1025,13 +1025,11 @@ if (__DEV__) {
10251025
*/
10261026

10271027
function isValidElement(object) {
1028-
{
1029-
return (
1030-
typeof object === "object" &&
1031-
object !== null &&
1032-
object.$$typeof === REACT_ELEMENT_TYPE
1033-
);
1034-
}
1028+
return (
1029+
typeof object === "object" &&
1030+
object !== null &&
1031+
object.$$typeof === REACT_ELEMENT_TYPE
1032+
);
10351033
}
10361034
var ownerHasKeyUseWarning = {};
10371035
/**

compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/JSXRuntime-dev.js

+6-8
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* @noflow
88
* @nolint
99
* @preventMunge
10-
* @generated SignedSource<<040e6a4059e2c6d1c22e6d708cbf3b39>>
10+
* @generated SignedSource<<8af9696c59d9d4cfa4cc835b5a54e94e>>
1111
*/
1212

1313
"use strict";
@@ -1061,13 +1061,11 @@ if (__DEV__) {
10611061
*/
10621062

10631063
function isValidElement(object) {
1064-
{
1065-
return (
1066-
typeof object === "object" &&
1067-
object !== null &&
1068-
object.$$typeof === REACT_ELEMENT_TYPE
1069-
);
1070-
}
1064+
return (
1065+
typeof object === "object" &&
1066+
object !== null &&
1067+
object.$$typeof === REACT_ELEMENT_TYPE
1068+
);
10711069
}
10721070
var ownerHasKeyUseWarning = {};
10731071
/**

0 commit comments

Comments
 (0)