react-server-dom-webpack 19.0.0-rc-68dbd84b-20240812 → 19.0.0-rc-49496d49-20240814
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/react-server-dom-webpack-server.browser.development.js +72 -62
- package/cjs/react-server-dom-webpack-server.browser.production.js +19 -9
- package/cjs/react-server-dom-webpack-server.edge.development.js +72 -62
- package/cjs/react-server-dom-webpack-server.edge.production.js +19 -9
- package/cjs/react-server-dom-webpack-server.node.development.js +72 -62
- package/cjs/react-server-dom-webpack-server.node.production.js +19 -9
- package/cjs/react-server-dom-webpack-server.node.unbundled.development.js +72 -62
- package/cjs/react-server-dom-webpack-server.node.unbundled.production.js +19 -9
- package/package.json +3 -3
@@ -11,6 +11,7 @@
|
|
11
11
|
"use strict";
|
12
12
|
"production" !== process.env.NODE_ENV &&
|
13
13
|
(function () {
|
14
|
+
function voidHandler() {}
|
14
15
|
function _defineProperty(obj, key, value) {
|
15
16
|
key in obj
|
16
17
|
? Object.defineProperty(obj, key, {
|
@@ -70,6 +71,9 @@
|
|
70
71
|
? destination.error(error)
|
71
72
|
: destination.close();
|
72
73
|
}
|
74
|
+
function isClientReference(reference) {
|
75
|
+
return reference.$$typeof === CLIENT_REFERENCE_TAG$1;
|
76
|
+
}
|
73
77
|
function registerClientReferenceImpl(proxyImplementation, id, async) {
|
74
78
|
return Object.defineProperties(proxyImplementation, {
|
75
79
|
$$typeof: { value: CLIENT_REFERENCE_TAG$1 },
|
@@ -573,6 +577,8 @@
|
|
573
577
|
task = thenable.reason;
|
574
578
|
var digest = logRecoverableError(request, task, null);
|
575
579
|
emitErrorChunk(request, newTask.id, digest, task);
|
580
|
+
newTask.status = 4;
|
581
|
+
request.abortableTasks.delete(newTask);
|
576
582
|
return newTask.id;
|
577
583
|
default:
|
578
584
|
if (1 === request.status)
|
@@ -603,9 +609,9 @@
|
|
603
609
|
pingTask(request, newTask);
|
604
610
|
},
|
605
611
|
function (reason) {
|
606
|
-
newTask.status = 4;
|
607
612
|
var _digest = logRecoverableError(request, reason, newTask);
|
608
613
|
emitErrorChunk(request, newTask.id, _digest, reason);
|
614
|
+
newTask.status = 4;
|
609
615
|
request.abortableTasks.delete(newTask);
|
610
616
|
enqueueFlush(request);
|
611
617
|
}
|
@@ -808,23 +814,28 @@
|
|
808
814
|
}
|
809
815
|
prepareToUseHooksForComponent(prevThenableState, componentDebugInfo);
|
810
816
|
props = callComponentInDEV(Component, props, componentDebugInfo);
|
811
|
-
if (1 === request.status)
|
817
|
+
if (1 === request.status)
|
818
|
+
throw (
|
819
|
+
("object" !== typeof props ||
|
820
|
+
null === props ||
|
821
|
+
"function" !== typeof props.then ||
|
822
|
+
isClientReference(props) ||
|
823
|
+
props.then(voidHandler, voidHandler),
|
824
|
+
null)
|
825
|
+
);
|
812
826
|
if (
|
813
827
|
"object" === typeof props &&
|
814
828
|
null !== props &&
|
815
|
-
props
|
829
|
+
!isClientReference(props)
|
816
830
|
) {
|
817
831
|
if ("function" === typeof props.then) {
|
818
832
|
prevThenableState = props;
|
819
|
-
prevThenableState.then(
|
820
|
-
|
821
|
-
|
822
|
-
|
823
|
-
|
824
|
-
|
825
|
-
},
|
826
|
-
function () {}
|
827
|
-
);
|
833
|
+
prevThenableState.then(function (resolvedValue) {
|
834
|
+
"object" === typeof resolvedValue &&
|
835
|
+
null !== resolvedValue &&
|
836
|
+
resolvedValue.$$typeof === REACT_ELEMENT_TYPE &&
|
837
|
+
(resolvedValue._store.validated = 1);
|
838
|
+
}, voidHandler);
|
828
839
|
if ("fulfilled" === prevThenableState.status)
|
829
840
|
return prevThenableState.value;
|
830
841
|
props = createLazyWrapperAroundWakeable(props);
|
@@ -950,48 +961,48 @@
|
|
950
961
|
null !== props.children &&
|
951
962
|
jsxChildrenParents.set(props.children, type);
|
952
963
|
if (
|
953
|
-
"function"
|
954
|
-
type
|
955
|
-
type.$$typeof
|
956
|
-
)
|
957
|
-
|
958
|
-
|
959
|
-
|
960
|
-
|
961
|
-
|
962
|
-
(props = renderModelDestructive(
|
963
|
-
request,
|
964
|
-
task,
|
965
|
-
emptyRoot,
|
966
|
-
"",
|
967
|
-
props.children
|
968
|
-
)),
|
969
|
-
(task.implicitSlot = type),
|
970
|
-
props
|
971
|
-
);
|
972
|
-
if (
|
973
|
-
null != type &&
|
974
|
-
"object" === typeof type &&
|
975
|
-
type.$$typeof !== CLIENT_REFERENCE_TAG$1
|
976
|
-
)
|
977
|
-
switch (type.$$typeof) {
|
978
|
-
case REACT_LAZY_TYPE:
|
979
|
-
type = callLazyInitInDEV(type);
|
980
|
-
if (1 === request.status) throw AbortSigil;
|
981
|
-
return renderElement(request, task, type, key, ref, props);
|
982
|
-
case REACT_FORWARD_REF_TYPE:
|
983
|
-
return renderFunctionComponent(
|
964
|
+
"function" !== typeof type ||
|
965
|
+
isClientReference(type) ||
|
966
|
+
type.$$typeof === TEMPORARY_REFERENCE_TAG
|
967
|
+
) {
|
968
|
+
if (type === REACT_FRAGMENT_TYPE && null === key)
|
969
|
+
return (
|
970
|
+
(type = task.implicitSlot),
|
971
|
+
null === task.keyPath && (task.implicitSlot = !0),
|
972
|
+
(props = renderModelDestructive(
|
984
973
|
request,
|
985
974
|
task,
|
986
|
-
|
987
|
-
|
988
|
-
props
|
989
|
-
)
|
990
|
-
|
991
|
-
|
992
|
-
|
993
|
-
|
994
|
-
|
975
|
+
emptyRoot,
|
976
|
+
"",
|
977
|
+
props.children
|
978
|
+
)),
|
979
|
+
(task.implicitSlot = type),
|
980
|
+
props
|
981
|
+
);
|
982
|
+
if (
|
983
|
+
null != type &&
|
984
|
+
"object" === typeof type &&
|
985
|
+
!isClientReference(type)
|
986
|
+
)
|
987
|
+
switch (type.$$typeof) {
|
988
|
+
case REACT_LAZY_TYPE:
|
989
|
+
type = callLazyInitInDEV(type);
|
990
|
+
if (1 === request.status) throw null;
|
991
|
+
return renderElement(request, task, type, key, ref, props);
|
992
|
+
case REACT_FORWARD_REF_TYPE:
|
993
|
+
return renderFunctionComponent(
|
994
|
+
request,
|
995
|
+
task,
|
996
|
+
key,
|
997
|
+
type.render,
|
998
|
+
props
|
999
|
+
);
|
1000
|
+
case REACT_MEMO_TYPE:
|
1001
|
+
return renderElement(request, task, type.type, key, ref, props);
|
1002
|
+
case REACT_ELEMENT_TYPE:
|
1003
|
+
type._store.validated = 1;
|
1004
|
+
}
|
1005
|
+
} else return renderFunctionComponent(request, task, key, type, props);
|
995
1006
|
request = key;
|
996
1007
|
key = task.keyPath;
|
997
1008
|
null === request
|
@@ -1289,7 +1300,7 @@
|
|
1289
1300
|
? serializeLazyID(request.id)
|
1290
1301
|
: serializeByValueID(request.id);
|
1291
1302
|
}
|
1292
|
-
if (
|
1303
|
+
if (1 === request.status)
|
1293
1304
|
return (
|
1294
1305
|
(task.status = 3),
|
1295
1306
|
(task = request.fatalError),
|
@@ -1358,7 +1369,7 @@
|
|
1358
1369
|
case REACT_LAZY_TYPE:
|
1359
1370
|
task.thenableState = null;
|
1360
1371
|
elementReference = callLazyInitInDEV(value);
|
1361
|
-
if (1 === request.status) throw
|
1372
|
+
if (1 === request.status) throw null;
|
1362
1373
|
if ((_writtenObjects = value._debugInfo)) {
|
1363
1374
|
if (null === debugID) return outlineTask(request, task);
|
1364
1375
|
forwardDebugInfo(request, debugID, _writtenObjects);
|
@@ -1375,7 +1386,7 @@
|
|
1375
1386
|
'A React Element from an older version of React was rendered. This is not supported. It can happen if:\n- Multiple copies of the "react" package is used.\n- A library pre-bundled an old copy of "react" or "react/jsx-runtime".\n- A compiler tries to "inline" JSX instead of using the runtime.'
|
1376
1387
|
);
|
1377
1388
|
}
|
1378
|
-
if (value
|
1389
|
+
if (isClientReference(value))
|
1379
1390
|
return serializeClientReference(
|
1380
1391
|
request,
|
1381
1392
|
parent,
|
@@ -1530,7 +1541,7 @@
|
|
1530
1541
|
if ("number" === typeof value) return serializeNumber(value);
|
1531
1542
|
if ("undefined" === typeof value) return "$undefined";
|
1532
1543
|
if ("function" === typeof value) {
|
1533
|
-
if (value
|
1544
|
+
if (isClientReference(value))
|
1534
1545
|
return serializeClientReference(
|
1535
1546
|
request,
|
1536
1547
|
parent,
|
@@ -1767,7 +1778,7 @@
|
|
1767
1778
|
var originalValue = parent[parentPropertyName];
|
1768
1779
|
if (null === value) return null;
|
1769
1780
|
if ("object" === typeof value) {
|
1770
|
-
if (value
|
1781
|
+
if (isClientReference(value))
|
1771
1782
|
return serializeClientReference(
|
1772
1783
|
request,
|
1773
1784
|
parent,
|
@@ -1878,7 +1889,7 @@
|
|
1878
1889
|
if ("number" === typeof value) return serializeNumber(value);
|
1879
1890
|
if ("undefined" === typeof value) return "$undefined";
|
1880
1891
|
if ("function" === typeof value)
|
1881
|
-
return value
|
1892
|
+
return isClientReference(value)
|
1882
1893
|
? serializeClientReference(request, parent, parentPropertyName, value)
|
1883
1894
|
: void 0 !== request.temporaryReferences &&
|
1884
1895
|
((request = request.temporaryReferences.get(value)),
|
@@ -2016,7 +2027,7 @@
|
|
2016
2027
|
var ping = task.ping;
|
2017
2028
|
x.then(ping, ping);
|
2018
2029
|
}
|
2019
|
-
else if (
|
2030
|
+
else if (1 === request.status) {
|
2020
2031
|
request.abortableTasks.delete(task);
|
2021
2032
|
task.status = 3;
|
2022
2033
|
var _model = stringify(serializeByValueID(request.fatalError));
|
@@ -2143,7 +2154,7 @@
|
|
2143
2154
|
}
|
2144
2155
|
function abort(request, reason) {
|
2145
2156
|
try {
|
2146
|
-
request.status = 1;
|
2157
|
+
0 === request.status && (request.status = 1);
|
2147
2158
|
var abortableTasks = request.abortableTasks;
|
2148
2159
|
if (0 < abortableTasks.size) {
|
2149
2160
|
request.pendingChunks++;
|
@@ -3260,7 +3271,7 @@
|
|
3260
3271
|
}
|
3261
3272
|
usable.$$typeof === REACT_CONTEXT_TYPE && unsupportedContext();
|
3262
3273
|
}
|
3263
|
-
if (usable
|
3274
|
+
if (isClientReference(usable)) {
|
3264
3275
|
if (
|
3265
3276
|
null != usable.value &&
|
3266
3277
|
usable.value.$$typeof === REACT_CONTEXT_TYPE
|
@@ -3335,7 +3346,6 @@
|
|
3335
3346
|
CLIENT_REFERENCE_TAG = Symbol.for("react.client.reference"),
|
3336
3347
|
ObjectPrototype = Object.prototype,
|
3337
3348
|
stringify = JSON.stringify,
|
3338
|
-
AbortSigil = {},
|
3339
3349
|
CLOSED = 3,
|
3340
3350
|
currentRequest = null,
|
3341
3351
|
debugID = null,
|
@@ -701,8 +701,7 @@ function describeObjectForErrorMessage(objectOrArray, expandedName) {
|
|
701
701
|
: "\n " + str;
|
702
702
|
}
|
703
703
|
var ObjectPrototype = Object.prototype,
|
704
|
-
stringify = JSON.stringify
|
705
|
-
AbortSigil = {};
|
704
|
+
stringify = JSON.stringify;
|
706
705
|
function defaultErrorHandler(error) {
|
707
706
|
console.error(error);
|
708
707
|
}
|
@@ -769,6 +768,8 @@ function serializeThenable(request, task, thenable) {
|
|
769
768
|
return (
|
770
769
|
(task = logRecoverableError(request, thenable.reason, null)),
|
771
770
|
emitErrorChunk(request, newTask.id, task),
|
771
|
+
(newTask.status = 4),
|
772
|
+
request.abortableTasks.delete(newTask),
|
772
773
|
newTask.id
|
773
774
|
);
|
774
775
|
default:
|
@@ -800,9 +801,9 @@ function serializeThenable(request, task, thenable) {
|
|
800
801
|
pingTask(request, newTask);
|
801
802
|
},
|
802
803
|
function (reason) {
|
803
|
-
newTask.status = 4;
|
804
804
|
reason = logRecoverableError(request, reason, newTask);
|
805
805
|
emitErrorChunk(request, newTask.id, reason);
|
806
|
+
newTask.status = 4;
|
806
807
|
request.abortableTasks.delete(newTask);
|
807
808
|
enqueueFlush(request);
|
808
809
|
}
|
@@ -960,13 +961,22 @@ function createLazyWrapperAroundWakeable(wakeable) {
|
|
960
961
|
}
|
961
962
|
return { $$typeof: REACT_LAZY_TYPE, _payload: wakeable, _init: readThenable };
|
962
963
|
}
|
964
|
+
function voidHandler() {}
|
963
965
|
function renderFunctionComponent(request, task, key, Component, props) {
|
964
966
|
var prevThenableState = task.thenableState;
|
965
967
|
task.thenableState = null;
|
966
968
|
thenableIndexCounter = 0;
|
967
969
|
thenableState = prevThenableState;
|
968
970
|
Component = Component(props, void 0);
|
969
|
-
if (1 === request.status)
|
971
|
+
if (1 === request.status)
|
972
|
+
throw (
|
973
|
+
("object" === typeof Component &&
|
974
|
+
null !== Component &&
|
975
|
+
"function" === typeof Component.then &&
|
976
|
+
Component.$$typeof !== CLIENT_REFERENCE_TAG$1 &&
|
977
|
+
Component.then(voidHandler, voidHandler),
|
978
|
+
null)
|
979
|
+
);
|
970
980
|
if (
|
971
981
|
"object" === typeof Component &&
|
972
982
|
null !== Component &&
|
@@ -1057,7 +1067,7 @@ function renderElement(request, task, type, key, ref, props) {
|
|
1057
1067
|
case REACT_LAZY_TYPE:
|
1058
1068
|
var init = type._init;
|
1059
1069
|
type = init(type._payload);
|
1060
|
-
if (1 === request.status) throw
|
1070
|
+
if (1 === request.status) throw null;
|
1061
1071
|
return renderElement(request, task, type, key, ref, props);
|
1062
1072
|
case REACT_FORWARD_REF_TYPE:
|
1063
1073
|
return renderFunctionComponent(request, task, key, type.render, props);
|
@@ -1151,7 +1161,7 @@ function createTask(request, model, keyPath, implicitSlot, abortSet) {
|
|
1151
1161
|
: serializeByValueID(JSCompiler_inline_result.id);
|
1152
1162
|
}
|
1153
1163
|
else
|
1154
|
-
|
1164
|
+
1 === request.status
|
1155
1165
|
? ((task.status = 3),
|
1156
1166
|
(prevKeyPath = request.fatalError),
|
1157
1167
|
(JSCompiler_inline_result = parentPropertyName
|
@@ -1329,7 +1339,7 @@ function renderModelDestructive(
|
|
1329
1339
|
task.thenableState = null;
|
1330
1340
|
parentPropertyName = value._init;
|
1331
1341
|
value = parentPropertyName(value._payload);
|
1332
|
-
if (1 === request.status) throw
|
1342
|
+
if (1 === request.status) throw null;
|
1333
1343
|
return renderModelDestructive(request, task, emptyRoot, "", value);
|
1334
1344
|
case REACT_LEGACY_ELEMENT_TYPE:
|
1335
1345
|
throw Error(
|
@@ -1707,7 +1717,7 @@ function retryTask(request, task) {
|
|
1707
1717
|
var ping = task.ping;
|
1708
1718
|
x.then(ping, ping);
|
1709
1719
|
}
|
1710
|
-
else if (
|
1720
|
+
else if (1 === request.status) {
|
1711
1721
|
request.abortableTasks.delete(task);
|
1712
1722
|
task.status = 3;
|
1713
1723
|
var model$19 = stringify(serializeByValueID(request.fatalError));
|
@@ -1799,7 +1809,7 @@ function enqueueFlush(request) {
|
|
1799
1809
|
}
|
1800
1810
|
function abort(request, reason) {
|
1801
1811
|
try {
|
1802
|
-
request.status = 1;
|
1812
|
+
0 === request.status && (request.status = 1);
|
1803
1813
|
var abortableTasks = request.abortableTasks;
|
1804
1814
|
if (0 < abortableTasks.size) {
|
1805
1815
|
request.pendingChunks++;
|
@@ -11,6 +11,7 @@
|
|
11
11
|
"use strict";
|
12
12
|
"production" !== process.env.NODE_ENV &&
|
13
13
|
(function () {
|
14
|
+
function voidHandler() {}
|
14
15
|
function _defineProperty(obj, key, value) {
|
15
16
|
key in obj
|
16
17
|
? Object.defineProperty(obj, key, {
|
@@ -66,6 +67,9 @@
|
|
66
67
|
? destination.error(error)
|
67
68
|
: destination.close();
|
68
69
|
}
|
70
|
+
function isClientReference(reference) {
|
71
|
+
return reference.$$typeof === CLIENT_REFERENCE_TAG$1;
|
72
|
+
}
|
69
73
|
function registerClientReferenceImpl(proxyImplementation, id, async) {
|
70
74
|
return Object.defineProperties(proxyImplementation, {
|
71
75
|
$$typeof: { value: CLIENT_REFERENCE_TAG$1 },
|
@@ -577,6 +581,8 @@
|
|
577
581
|
task = thenable.reason;
|
578
582
|
var digest = logRecoverableError(request, task, null);
|
579
583
|
emitErrorChunk(request, newTask.id, digest, task);
|
584
|
+
newTask.status = 4;
|
585
|
+
request.abortableTasks.delete(newTask);
|
580
586
|
return newTask.id;
|
581
587
|
default:
|
582
588
|
if (1 === request.status)
|
@@ -607,9 +613,9 @@
|
|
607
613
|
pingTask(request, newTask);
|
608
614
|
},
|
609
615
|
function (reason) {
|
610
|
-
newTask.status = 4;
|
611
616
|
var _digest = logRecoverableError(request, reason, newTask);
|
612
617
|
emitErrorChunk(request, newTask.id, _digest, reason);
|
618
|
+
newTask.status = 4;
|
613
619
|
request.abortableTasks.delete(newTask);
|
614
620
|
enqueueFlush(request);
|
615
621
|
}
|
@@ -820,23 +826,28 @@
|
|
820
826
|
componentDebugInfo
|
821
827
|
)
|
822
828
|
: callComponentInDEV(Component, props, componentDebugInfo);
|
823
|
-
if (1 === request.status)
|
829
|
+
if (1 === request.status)
|
830
|
+
throw (
|
831
|
+
("object" !== typeof props ||
|
832
|
+
null === props ||
|
833
|
+
"function" !== typeof props.then ||
|
834
|
+
isClientReference(props) ||
|
835
|
+
props.then(voidHandler, voidHandler),
|
836
|
+
null)
|
837
|
+
);
|
824
838
|
if (
|
825
839
|
"object" === typeof props &&
|
826
840
|
null !== props &&
|
827
|
-
props
|
841
|
+
!isClientReference(props)
|
828
842
|
) {
|
829
843
|
if ("function" === typeof props.then) {
|
830
844
|
prevThenableState = props;
|
831
|
-
prevThenableState.then(
|
832
|
-
|
833
|
-
|
834
|
-
|
835
|
-
|
836
|
-
|
837
|
-
},
|
838
|
-
function () {}
|
839
|
-
);
|
845
|
+
prevThenableState.then(function (resolvedValue) {
|
846
|
+
"object" === typeof resolvedValue &&
|
847
|
+
null !== resolvedValue &&
|
848
|
+
resolvedValue.$$typeof === REACT_ELEMENT_TYPE &&
|
849
|
+
(resolvedValue._store.validated = 1);
|
850
|
+
}, voidHandler);
|
840
851
|
if ("fulfilled" === prevThenableState.status)
|
841
852
|
return prevThenableState.value;
|
842
853
|
props = createLazyWrapperAroundWakeable(props);
|
@@ -962,48 +973,48 @@
|
|
962
973
|
null !== props.children &&
|
963
974
|
jsxChildrenParents.set(props.children, type);
|
964
975
|
if (
|
965
|
-
"function"
|
966
|
-
type
|
967
|
-
type.$$typeof
|
968
|
-
)
|
969
|
-
|
970
|
-
|
971
|
-
|
972
|
-
|
973
|
-
|
974
|
-
(props = renderModelDestructive(
|
975
|
-
request,
|
976
|
-
task,
|
977
|
-
emptyRoot,
|
978
|
-
"",
|
979
|
-
props.children
|
980
|
-
)),
|
981
|
-
(task.implicitSlot = type),
|
982
|
-
props
|
983
|
-
);
|
984
|
-
if (
|
985
|
-
null != type &&
|
986
|
-
"object" === typeof type &&
|
987
|
-
type.$$typeof !== CLIENT_REFERENCE_TAG$1
|
988
|
-
)
|
989
|
-
switch (type.$$typeof) {
|
990
|
-
case REACT_LAZY_TYPE:
|
991
|
-
type = callLazyInitInDEV(type);
|
992
|
-
if (1 === request.status) throw AbortSigil;
|
993
|
-
return renderElement(request, task, type, key, ref, props);
|
994
|
-
case REACT_FORWARD_REF_TYPE:
|
995
|
-
return renderFunctionComponent(
|
976
|
+
"function" !== typeof type ||
|
977
|
+
isClientReference(type) ||
|
978
|
+
type.$$typeof === TEMPORARY_REFERENCE_TAG
|
979
|
+
) {
|
980
|
+
if (type === REACT_FRAGMENT_TYPE && null === key)
|
981
|
+
return (
|
982
|
+
(type = task.implicitSlot),
|
983
|
+
null === task.keyPath && (task.implicitSlot = !0),
|
984
|
+
(props = renderModelDestructive(
|
996
985
|
request,
|
997
986
|
task,
|
998
|
-
|
999
|
-
|
1000
|
-
props
|
1001
|
-
)
|
1002
|
-
|
1003
|
-
|
1004
|
-
|
1005
|
-
|
1006
|
-
|
987
|
+
emptyRoot,
|
988
|
+
"",
|
989
|
+
props.children
|
990
|
+
)),
|
991
|
+
(task.implicitSlot = type),
|
992
|
+
props
|
993
|
+
);
|
994
|
+
if (
|
995
|
+
null != type &&
|
996
|
+
"object" === typeof type &&
|
997
|
+
!isClientReference(type)
|
998
|
+
)
|
999
|
+
switch (type.$$typeof) {
|
1000
|
+
case REACT_LAZY_TYPE:
|
1001
|
+
type = callLazyInitInDEV(type);
|
1002
|
+
if (1 === request.status) throw null;
|
1003
|
+
return renderElement(request, task, type, key, ref, props);
|
1004
|
+
case REACT_FORWARD_REF_TYPE:
|
1005
|
+
return renderFunctionComponent(
|
1006
|
+
request,
|
1007
|
+
task,
|
1008
|
+
key,
|
1009
|
+
type.render,
|
1010
|
+
props
|
1011
|
+
);
|
1012
|
+
case REACT_MEMO_TYPE:
|
1013
|
+
return renderElement(request, task, type.type, key, ref, props);
|
1014
|
+
case REACT_ELEMENT_TYPE:
|
1015
|
+
type._store.validated = 1;
|
1016
|
+
}
|
1017
|
+
} else return renderFunctionComponent(request, task, key, type, props);
|
1007
1018
|
request = key;
|
1008
1019
|
key = task.keyPath;
|
1009
1020
|
null === request
|
@@ -1301,7 +1312,7 @@
|
|
1301
1312
|
? serializeLazyID(request.id)
|
1302
1313
|
: serializeByValueID(request.id);
|
1303
1314
|
}
|
1304
|
-
if (
|
1315
|
+
if (1 === request.status)
|
1305
1316
|
return (
|
1306
1317
|
(task.status = 3),
|
1307
1318
|
(task = request.fatalError),
|
@@ -1370,7 +1381,7 @@
|
|
1370
1381
|
case REACT_LAZY_TYPE:
|
1371
1382
|
task.thenableState = null;
|
1372
1383
|
elementReference = callLazyInitInDEV(value);
|
1373
|
-
if (1 === request.status) throw
|
1384
|
+
if (1 === request.status) throw null;
|
1374
1385
|
if ((_writtenObjects = value._debugInfo)) {
|
1375
1386
|
if (null === debugID) return outlineTask(request, task);
|
1376
1387
|
forwardDebugInfo(request, debugID, _writtenObjects);
|
@@ -1387,7 +1398,7 @@
|
|
1387
1398
|
'A React Element from an older version of React was rendered. This is not supported. It can happen if:\n- Multiple copies of the "react" package is used.\n- A library pre-bundled an old copy of "react" or "react/jsx-runtime".\n- A compiler tries to "inline" JSX instead of using the runtime.'
|
1388
1399
|
);
|
1389
1400
|
}
|
1390
|
-
if (value
|
1401
|
+
if (isClientReference(value))
|
1391
1402
|
return serializeClientReference(
|
1392
1403
|
request,
|
1393
1404
|
parent,
|
@@ -1542,7 +1553,7 @@
|
|
1542
1553
|
if ("number" === typeof value) return serializeNumber(value);
|
1543
1554
|
if ("undefined" === typeof value) return "$undefined";
|
1544
1555
|
if ("function" === typeof value) {
|
1545
|
-
if (value
|
1556
|
+
if (isClientReference(value))
|
1546
1557
|
return serializeClientReference(
|
1547
1558
|
request,
|
1548
1559
|
parent,
|
@@ -1790,7 +1801,7 @@
|
|
1790
1801
|
var originalValue = parent[parentPropertyName];
|
1791
1802
|
if (null === value) return null;
|
1792
1803
|
if ("object" === typeof value) {
|
1793
|
-
if (value
|
1804
|
+
if (isClientReference(value))
|
1794
1805
|
return serializeClientReference(
|
1795
1806
|
request,
|
1796
1807
|
parent,
|
@@ -1901,7 +1912,7 @@
|
|
1901
1912
|
if ("number" === typeof value) return serializeNumber(value);
|
1902
1913
|
if ("undefined" === typeof value) return "$undefined";
|
1903
1914
|
if ("function" === typeof value)
|
1904
|
-
return value
|
1915
|
+
return isClientReference(value)
|
1905
1916
|
? serializeClientReference(request, parent, parentPropertyName, value)
|
1906
1917
|
: void 0 !== request.temporaryReferences &&
|
1907
1918
|
((request = request.temporaryReferences.get(value)),
|
@@ -2039,7 +2050,7 @@
|
|
2039
2050
|
var ping = task.ping;
|
2040
2051
|
x.then(ping, ping);
|
2041
2052
|
}
|
2042
|
-
else if (
|
2053
|
+
else if (1 === request.status) {
|
2043
2054
|
request.abortableTasks.delete(task);
|
2044
2055
|
task.status = 3;
|
2045
2056
|
var _model = stringify(serializeByValueID(request.fatalError));
|
@@ -2170,7 +2181,7 @@
|
|
2170
2181
|
}
|
2171
2182
|
function abort(request, reason) {
|
2172
2183
|
try {
|
2173
|
-
request.status = 1;
|
2184
|
+
0 === request.status && (request.status = 1);
|
2174
2185
|
var abortableTasks = request.abortableTasks;
|
2175
2186
|
if (0 < abortableTasks.size) {
|
2176
2187
|
request.pendingChunks++;
|
@@ -3289,7 +3300,7 @@
|
|
3289
3300
|
}
|
3290
3301
|
usable.$$typeof === REACT_CONTEXT_TYPE && unsupportedContext();
|
3291
3302
|
}
|
3292
|
-
if (usable
|
3303
|
+
if (isClientReference(usable)) {
|
3293
3304
|
if (
|
3294
3305
|
null != usable.value &&
|
3295
3306
|
usable.value.$$typeof === REACT_CONTEXT_TYPE
|
@@ -3367,7 +3378,6 @@
|
|
3367
3378
|
CLIENT_REFERENCE_TAG = Symbol.for("react.client.reference"),
|
3368
3379
|
ObjectPrototype = Object.prototype,
|
3369
3380
|
stringify = JSON.stringify,
|
3370
|
-
AbortSigil = {},
|
3371
3381
|
CLOSED = 3,
|
3372
3382
|
currentRequest = null,
|
3373
3383
|
debugID = null,
|