react-server-dom-webpack 19.2.0-canary-96c61b7f-20250709 → 19.2.0-canary-2f0e7e57-20250715
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-client.browser.development.js +247 -94
- package/cjs/react-server-dom-webpack-client.browser.production.js +29 -22
- package/cjs/react-server-dom-webpack-client.edge.development.js +30 -10
- package/cjs/react-server-dom-webpack-client.edge.production.js +17 -12
- package/cjs/react-server-dom-webpack-client.node.development.js +60 -42
- package/cjs/react-server-dom-webpack-client.node.production.js +38 -35
- package/cjs/react-server-dom-webpack-client.node.unbundled.development.js +60 -42
- package/cjs/react-server-dom-webpack-client.node.unbundled.production.js +38 -35
- package/cjs/react-server-dom-webpack-server.browser.development.js +228 -141
- package/cjs/react-server-dom-webpack-server.browser.production.js +45 -45
- package/cjs/react-server-dom-webpack-server.edge.development.js +228 -141
- package/cjs/react-server-dom-webpack-server.edge.production.js +45 -45
- package/cjs/react-server-dom-webpack-server.node.development.js +287 -152
- package/cjs/react-server-dom-webpack-server.node.production.js +68 -69
- package/cjs/react-server-dom-webpack-server.node.unbundled.development.js +287 -152
- package/cjs/react-server-dom-webpack-server.node.unbundled.production.js +68 -69
- package/package.json +3 -3
@@ -1346,6 +1346,13 @@
|
|
1346
1346
|
map,
|
1347
1347
|
path
|
1348
1348
|
) {
|
1349
|
+
if (
|
1350
|
+
void 0 === response._debugChannel &&
|
1351
|
+
"pending" === referencedChunk.status &&
|
1352
|
+
parentObject[0] === REACT_ELEMENT_TYPE &&
|
1353
|
+
("4" === key || "5" === key)
|
1354
|
+
)
|
1355
|
+
return null;
|
1349
1356
|
if (initializingHandler) {
|
1350
1357
|
var handler = initializingHandler;
|
1351
1358
|
handler.deps++;
|
@@ -1853,8 +1860,6 @@
|
|
1853
1860
|
this._chunks = chunks;
|
1854
1861
|
this._stringDecoder = new TextDecoder();
|
1855
1862
|
this._fromJSON = null;
|
1856
|
-
this._rowLength = this._rowTag = this._rowID = this._rowState = 0;
|
1857
|
-
this._buffer = [];
|
1858
1863
|
this._closed = !1;
|
1859
1864
|
this._closedReason = null;
|
1860
1865
|
this._tempRefs = temporaryReferences;
|
@@ -1882,6 +1887,15 @@
|
|
1882
1887
|
: debugChannelRegistry.register(this, debugChannel));
|
1883
1888
|
this._fromJSON = createFromJSONCallback(this);
|
1884
1889
|
}
|
1890
|
+
function createStreamState() {
|
1891
|
+
return {
|
1892
|
+
_rowState: 0,
|
1893
|
+
_rowID: 0,
|
1894
|
+
_rowTag: 0,
|
1895
|
+
_rowLength: 0,
|
1896
|
+
_buffer: []
|
1897
|
+
};
|
1898
|
+
}
|
1885
1899
|
function resolveDebugHalt(response, id) {
|
1886
1900
|
var chunks = response._chunks,
|
1887
1901
|
chunk = chunks.get(id);
|
@@ -2657,6 +2671,96 @@
|
|
2657
2671
|
: resolveModel(response, id, row);
|
2658
2672
|
}
|
2659
2673
|
}
|
2674
|
+
function processBinaryChunk(weakResponse, streamState, chunk) {
|
2675
|
+
if (void 0 !== weakResponse.weak.deref()) {
|
2676
|
+
var response = unwrapWeakResponse(weakResponse),
|
2677
|
+
i = 0,
|
2678
|
+
rowState = streamState._rowState;
|
2679
|
+
weakResponse = streamState._rowID;
|
2680
|
+
for (
|
2681
|
+
var rowTag = streamState._rowTag,
|
2682
|
+
rowLength = streamState._rowLength,
|
2683
|
+
buffer = streamState._buffer,
|
2684
|
+
chunkLength = chunk.length;
|
2685
|
+
i < chunkLength;
|
2686
|
+
|
2687
|
+
) {
|
2688
|
+
var lastIdx = -1;
|
2689
|
+
switch (rowState) {
|
2690
|
+
case 0:
|
2691
|
+
lastIdx = chunk[i++];
|
2692
|
+
58 === lastIdx
|
2693
|
+
? (rowState = 1)
|
2694
|
+
: (weakResponse =
|
2695
|
+
(weakResponse << 4) |
|
2696
|
+
(96 < lastIdx ? lastIdx - 87 : lastIdx - 48));
|
2697
|
+
continue;
|
2698
|
+
case 1:
|
2699
|
+
rowState = chunk[i];
|
2700
|
+
84 === rowState ||
|
2701
|
+
65 === rowState ||
|
2702
|
+
79 === rowState ||
|
2703
|
+
111 === rowState ||
|
2704
|
+
85 === rowState ||
|
2705
|
+
83 === rowState ||
|
2706
|
+
115 === rowState ||
|
2707
|
+
76 === rowState ||
|
2708
|
+
108 === rowState ||
|
2709
|
+
71 === rowState ||
|
2710
|
+
103 === rowState ||
|
2711
|
+
77 === rowState ||
|
2712
|
+
109 === rowState ||
|
2713
|
+
86 === rowState
|
2714
|
+
? ((rowTag = rowState), (rowState = 2), i++)
|
2715
|
+
: (64 < rowState && 91 > rowState) ||
|
2716
|
+
35 === rowState ||
|
2717
|
+
114 === rowState ||
|
2718
|
+
120 === rowState
|
2719
|
+
? ((rowTag = rowState), (rowState = 3), i++)
|
2720
|
+
: ((rowTag = 0), (rowState = 3));
|
2721
|
+
continue;
|
2722
|
+
case 2:
|
2723
|
+
lastIdx = chunk[i++];
|
2724
|
+
44 === lastIdx
|
2725
|
+
? (rowState = 4)
|
2726
|
+
: (rowLength =
|
2727
|
+
(rowLength << 4) |
|
2728
|
+
(96 < lastIdx ? lastIdx - 87 : lastIdx - 48));
|
2729
|
+
continue;
|
2730
|
+
case 3:
|
2731
|
+
lastIdx = chunk.indexOf(10, i);
|
2732
|
+
break;
|
2733
|
+
case 4:
|
2734
|
+
(lastIdx = i + rowLength),
|
2735
|
+
lastIdx > chunk.length && (lastIdx = -1);
|
2736
|
+
}
|
2737
|
+
var offset = chunk.byteOffset + i;
|
2738
|
+
if (-1 < lastIdx)
|
2739
|
+
(rowLength = new Uint8Array(chunk.buffer, offset, lastIdx - i)),
|
2740
|
+
processFullBinaryRow(
|
2741
|
+
response,
|
2742
|
+
weakResponse,
|
2743
|
+
rowTag,
|
2744
|
+
buffer,
|
2745
|
+
rowLength
|
2746
|
+
),
|
2747
|
+
(i = lastIdx),
|
2748
|
+
3 === rowState && i++,
|
2749
|
+
(rowLength = weakResponse = rowTag = rowState = 0),
|
2750
|
+
(buffer.length = 0);
|
2751
|
+
else {
|
2752
|
+
chunk = new Uint8Array(chunk.buffer, offset, chunk.byteLength - i);
|
2753
|
+
buffer.push(chunk);
|
2754
|
+
rowLength -= chunk.byteLength;
|
2755
|
+
break;
|
2756
|
+
}
|
2757
|
+
}
|
2758
|
+
streamState._rowState = rowState;
|
2759
|
+
streamState._rowID = weakResponse;
|
2760
|
+
streamState._rowTag = rowTag;
|
2761
|
+
streamState._rowLength = rowLength;
|
2762
|
+
}
|
2763
|
+
}
|
2660
2764
|
function createFromJSONCallback(response) {
|
2661
2765
|
return function (key, value) {
|
2662
2766
|
if ("string" === typeof value)
|
@@ -2737,6 +2841,9 @@
|
|
2737
2841
|
return value;
|
2738
2842
|
};
|
2739
2843
|
}
|
2844
|
+
function close(weakResponse) {
|
2845
|
+
reportGlobalError(weakResponse, Error("Connection closed."));
|
2846
|
+
}
|
2740
2847
|
function createDebugCallbackFromWritableStream(debugWritable) {
|
2741
2848
|
var textEncoder = new TextEncoder(),
|
2742
2849
|
writer = debugWritable.getWriter();
|
@@ -2771,104 +2878,138 @@
|
|
2771
2878
|
debugChannel
|
2772
2879
|
)._weakResponse;
|
2773
2880
|
}
|
2774
|
-
function
|
2881
|
+
function startReadingFromUniversalStream(response$jscomp$0, stream) {
|
2775
2882
|
function progress(_ref) {
|
2776
2883
|
var value = _ref.value;
|
2777
|
-
if (_ref.done)
|
2884
|
+
if (_ref.done) close(response$jscomp$0);
|
2778
2885
|
else {
|
2779
|
-
if (
|
2780
|
-
|
2781
|
-
|
2782
|
-
|
2783
|
-
|
2784
|
-
|
2785
|
-
|
2786
|
-
|
2787
|
-
|
2788
|
-
chunkLength = value.length;
|
2789
|
-
i < chunkLength;
|
2790
|
-
|
2886
|
+
if (value instanceof ArrayBuffer)
|
2887
|
+
processBinaryChunk(
|
2888
|
+
response$jscomp$0,
|
2889
|
+
streamState,
|
2890
|
+
new Uint8Array(value)
|
2891
|
+
);
|
2892
|
+
else if ("string" === typeof value) {
|
2893
|
+
if (
|
2894
|
+
((_ref = streamState), void 0 !== response$jscomp$0.weak.deref())
|
2791
2895
|
) {
|
2792
|
-
|
2793
|
-
|
2794
|
-
|
2795
|
-
|
2796
|
-
|
2797
|
-
|
2798
|
-
|
2799
|
-
|
2800
|
-
|
2801
|
-
|
2802
|
-
|
2803
|
-
|
2804
|
-
|
2805
|
-
|
2806
|
-
|
2807
|
-
|
2808
|
-
|
2809
|
-
|
2810
|
-
|
2811
|
-
|
2812
|
-
|
2813
|
-
|
2814
|
-
|
2815
|
-
|
2816
|
-
|
2817
|
-
|
2818
|
-
|
2819
|
-
|
2820
|
-
|
2821
|
-
|
2822
|
-
|
2823
|
-
|
2824
|
-
|
2825
|
-
|
2826
|
-
|
2827
|
-
|
2828
|
-
|
2829
|
-
|
2830
|
-
|
2831
|
-
|
2832
|
-
|
2833
|
-
|
2834
|
-
|
2835
|
-
|
2836
|
-
|
2837
|
-
|
2838
|
-
|
2839
|
-
|
2840
|
-
|
2841
|
-
|
2842
|
-
|
2843
|
-
|
2844
|
-
|
2845
|
-
|
2846
|
-
|
2847
|
-
|
2848
|
-
|
2849
|
-
|
2850
|
-
|
2851
|
-
|
2852
|
-
|
2853
|
-
|
2854
|
-
|
2855
|
-
|
2856
|
-
|
2857
|
-
|
2896
|
+
for (
|
2897
|
+
var response = unwrapWeakResponse(response$jscomp$0),
|
2898
|
+
i = 0,
|
2899
|
+
rowState = _ref._rowState,
|
2900
|
+
rowID = _ref._rowID,
|
2901
|
+
rowTag = _ref._rowTag,
|
2902
|
+
rowLength = _ref._rowLength,
|
2903
|
+
buffer = _ref._buffer,
|
2904
|
+
chunkLength = value.length;
|
2905
|
+
i < chunkLength;
|
2906
|
+
|
2907
|
+
) {
|
2908
|
+
var lastIdx = -1;
|
2909
|
+
switch (rowState) {
|
2910
|
+
case 0:
|
2911
|
+
lastIdx = value.charCodeAt(i++);
|
2912
|
+
58 === lastIdx
|
2913
|
+
? (rowState = 1)
|
2914
|
+
: (rowID =
|
2915
|
+
(rowID << 4) |
|
2916
|
+
(96 < lastIdx ? lastIdx - 87 : lastIdx - 48));
|
2917
|
+
continue;
|
2918
|
+
case 1:
|
2919
|
+
rowState = value.charCodeAt(i);
|
2920
|
+
84 === rowState ||
|
2921
|
+
65 === rowState ||
|
2922
|
+
79 === rowState ||
|
2923
|
+
111 === rowState ||
|
2924
|
+
85 === rowState ||
|
2925
|
+
83 === rowState ||
|
2926
|
+
115 === rowState ||
|
2927
|
+
76 === rowState ||
|
2928
|
+
108 === rowState ||
|
2929
|
+
71 === rowState ||
|
2930
|
+
103 === rowState ||
|
2931
|
+
77 === rowState ||
|
2932
|
+
109 === rowState ||
|
2933
|
+
86 === rowState
|
2934
|
+
? ((rowTag = rowState), (rowState = 2), i++)
|
2935
|
+
: (64 < rowState && 91 > rowState) ||
|
2936
|
+
114 === rowState ||
|
2937
|
+
120 === rowState
|
2938
|
+
? ((rowTag = rowState), (rowState = 3), i++)
|
2939
|
+
: ((rowTag = 0), (rowState = 3));
|
2940
|
+
continue;
|
2941
|
+
case 2:
|
2942
|
+
lastIdx = value.charCodeAt(i++);
|
2943
|
+
44 === lastIdx
|
2944
|
+
? (rowState = 4)
|
2945
|
+
: (rowLength =
|
2946
|
+
(rowLength << 4) |
|
2947
|
+
(96 < lastIdx ? lastIdx - 87 : lastIdx - 48));
|
2948
|
+
continue;
|
2949
|
+
case 3:
|
2950
|
+
lastIdx = value.indexOf("\n", i);
|
2951
|
+
break;
|
2952
|
+
case 4:
|
2953
|
+
if (84 !== rowTag)
|
2954
|
+
throw Error(
|
2955
|
+
"Binary RSC chunks cannot be encoded as strings. This is a bug in the wiring of the React streams."
|
2956
|
+
);
|
2957
|
+
if (
|
2958
|
+
rowLength < value.length ||
|
2959
|
+
value.length > 3 * rowLength
|
2960
|
+
)
|
2961
|
+
throw Error(
|
2962
|
+
"String chunks need to be passed in their original shape. Not split into smaller string chunks. This is a bug in the wiring of the React streams."
|
2963
|
+
);
|
2964
|
+
lastIdx = value.length;
|
2965
|
+
}
|
2966
|
+
if (-1 < lastIdx) {
|
2967
|
+
if (0 < buffer.length)
|
2968
|
+
throw Error(
|
2969
|
+
"String chunks need to be passed in their original shape. Not split into smaller string chunks. This is a bug in the wiring of the React streams."
|
2970
|
+
);
|
2971
|
+
i = value.slice(i, lastIdx);
|
2972
|
+
processFullStringRow(response, rowID, rowTag, i);
|
2973
|
+
i = lastIdx;
|
2974
|
+
3 === rowState && i++;
|
2975
|
+
rowLength = rowID = rowTag = rowState = 0;
|
2976
|
+
buffer.length = 0;
|
2977
|
+
} else if (value.length !== i)
|
2978
|
+
throw Error(
|
2979
|
+
"String chunks need to be passed in their original shape. Not split into smaller string chunks. This is a bug in the wiring of the React streams."
|
2980
|
+
);
|
2858
2981
|
}
|
2982
|
+
_ref._rowState = rowState;
|
2983
|
+
_ref._rowID = rowID;
|
2984
|
+
_ref._rowTag = rowTag;
|
2985
|
+
_ref._rowLength = rowLength;
|
2859
2986
|
}
|
2860
|
-
|
2861
|
-
_ref._rowID = rowID;
|
2862
|
-
_ref._rowTag = rowTag;
|
2863
|
-
_ref._rowLength = rowLength;
|
2864
|
-
}
|
2987
|
+
} else processBinaryChunk(response$jscomp$0, streamState, value);
|
2865
2988
|
return reader.read().then(progress).catch(error);
|
2866
2989
|
}
|
2867
2990
|
}
|
2991
|
+
function error(e) {
|
2992
|
+
reportGlobalError(response$jscomp$0, e);
|
2993
|
+
}
|
2994
|
+
var streamState = createStreamState(),
|
2995
|
+
reader = stream.getReader();
|
2996
|
+
reader.read().then(progress).catch(error);
|
2997
|
+
}
|
2998
|
+
function startReadingFromStream(response, stream, isSecondaryStream) {
|
2999
|
+
function progress(_ref2) {
|
3000
|
+
var value = _ref2.value;
|
3001
|
+
if (_ref2.done) isSecondaryStream || close(response);
|
3002
|
+
else
|
3003
|
+
return (
|
3004
|
+
processBinaryChunk(response, streamState, value),
|
3005
|
+
reader.read().then(progress).catch(error)
|
3006
|
+
);
|
3007
|
+
}
|
2868
3008
|
function error(e) {
|
2869
3009
|
reportGlobalError(response, e);
|
2870
3010
|
}
|
2871
|
-
var
|
3011
|
+
var streamState = createStreamState(),
|
3012
|
+
reader = stream.getReader();
|
2872
3013
|
reader.read().then(progress).catch(error);
|
2873
3014
|
}
|
2874
3015
|
var React = require("react"),
|
@@ -3064,10 +3205,10 @@
|
|
3064
3205
|
return hook.checkDCE ? !0 : !1;
|
3065
3206
|
})({
|
3066
3207
|
bundleType: 1,
|
3067
|
-
version: "19.2.0-canary-
|
3208
|
+
version: "19.2.0-canary-2f0e7e57-20250715",
|
3068
3209
|
rendererPackageName: "react-server-dom-webpack",
|
3069
3210
|
currentDispatcherRef: ReactSharedInternals,
|
3070
|
-
reconcilerVersion: "19.2.0-canary-
|
3211
|
+
reconcilerVersion: "19.2.0-canary-2f0e7e57-20250715",
|
3071
3212
|
getCurrentComponentInfo: function () {
|
3072
3213
|
return currentOwnerInDEV;
|
3073
3214
|
}
|
@@ -3076,7 +3217,13 @@
|
|
3076
3217
|
var response = createResponseFromOptions(options);
|
3077
3218
|
promiseForResponse.then(
|
3078
3219
|
function (r) {
|
3079
|
-
|
3220
|
+
options && options.debugChannel && options.debugChannel.readable
|
3221
|
+
? (startReadingFromUniversalStream(
|
3222
|
+
response,
|
3223
|
+
options.debugChannel.readable
|
3224
|
+
),
|
3225
|
+
startReadingFromStream(response, r.body, !0))
|
3226
|
+
: startReadingFromStream(response, r.body, !1);
|
3080
3227
|
},
|
3081
3228
|
function (e) {
|
3082
3229
|
reportGlobalError(response, e);
|
@@ -3085,9 +3232,15 @@
|
|
3085
3232
|
return getRoot(response);
|
3086
3233
|
};
|
3087
3234
|
exports.createFromReadableStream = function (stream, options) {
|
3088
|
-
|
3089
|
-
|
3090
|
-
|
3235
|
+
var response = createResponseFromOptions(options);
|
3236
|
+
options && options.debugChannel && options.debugChannel.readable
|
3237
|
+
? (startReadingFromUniversalStream(
|
3238
|
+
response,
|
3239
|
+
options.debugChannel.readable
|
3240
|
+
),
|
3241
|
+
startReadingFromStream(response, stream, !0))
|
3242
|
+
: startReadingFromStream(response, stream, !1);
|
3243
|
+
return getRoot(response);
|
3091
3244
|
};
|
3092
3245
|
exports.createServerReference = function (
|
3093
3246
|
id,
|
@@ -1200,8 +1200,6 @@ function ResponseInstance(
|
|
1200
1200
|
this._chunks = chunks;
|
1201
1201
|
this._stringDecoder = new TextDecoder();
|
1202
1202
|
this._fromJSON = null;
|
1203
|
-
this._rowLength = this._rowTag = this._rowID = this._rowState = 0;
|
1204
|
-
this._buffer = [];
|
1205
1203
|
this._closed = !1;
|
1206
1204
|
this._closedReason = null;
|
1207
1205
|
this._tempRefs = temporaryReferences;
|
@@ -1666,18 +1664,20 @@ function createResponseFromOptions(options) {
|
|
1666
1664
|
: void 0
|
1667
1665
|
);
|
1668
1666
|
}
|
1669
|
-
function startReadingFromStream(response, stream) {
|
1670
|
-
function progress(
|
1671
|
-
var value =
|
1672
|
-
if (
|
1667
|
+
function startReadingFromStream(response, stream, isSecondaryStream) {
|
1668
|
+
function progress(_ref2) {
|
1669
|
+
var value = _ref2.value;
|
1670
|
+
if (_ref2.done)
|
1671
|
+
isSecondaryStream ||
|
1672
|
+
reportGlobalError(response, Error("Connection closed."));
|
1673
1673
|
else {
|
1674
1674
|
var i = 0,
|
1675
|
-
rowState =
|
1676
|
-
|
1675
|
+
rowState = streamState._rowState;
|
1676
|
+
_ref2 = streamState._rowID;
|
1677
1677
|
for (
|
1678
|
-
var rowTag =
|
1679
|
-
rowLength =
|
1680
|
-
buffer =
|
1678
|
+
var rowTag = streamState._rowTag,
|
1679
|
+
rowLength = streamState._rowLength,
|
1680
|
+
buffer = streamState._buffer,
|
1681
1681
|
chunkLength = value.length;
|
1682
1682
|
i < chunkLength;
|
1683
1683
|
|
@@ -1688,8 +1688,8 @@ function startReadingFromStream(response, stream) {
|
|
1688
1688
|
lastIdx = value[i++];
|
1689
1689
|
58 === lastIdx
|
1690
1690
|
? (rowState = 1)
|
1691
|
-
: (
|
1692
|
-
(
|
1691
|
+
: (_ref2 =
|
1692
|
+
(_ref2 << 4) | (96 < lastIdx ? lastIdx - 87 : lastIdx - 48));
|
1693
1693
|
continue;
|
1694
1694
|
case 1:
|
1695
1695
|
rowState = value[i];
|
@@ -1732,10 +1732,10 @@ function startReadingFromStream(response, stream) {
|
|
1732
1732
|
var offset = value.byteOffset + i;
|
1733
1733
|
if (-1 < lastIdx)
|
1734
1734
|
(rowLength = new Uint8Array(value.buffer, offset, lastIdx - i)),
|
1735
|
-
processFullBinaryRow(response,
|
1735
|
+
processFullBinaryRow(response, _ref2, rowTag, buffer, rowLength),
|
1736
1736
|
(i = lastIdx),
|
1737
1737
|
3 === rowState && i++,
|
1738
|
-
(rowLength =
|
1738
|
+
(rowLength = _ref2 = rowTag = rowState = 0),
|
1739
1739
|
(buffer.length = 0);
|
1740
1740
|
else {
|
1741
1741
|
value = new Uint8Array(value.buffer, offset, value.byteLength - i);
|
@@ -1744,24 +1744,31 @@ function startReadingFromStream(response, stream) {
|
|
1744
1744
|
break;
|
1745
1745
|
}
|
1746
1746
|
}
|
1747
|
-
|
1748
|
-
|
1749
|
-
|
1750
|
-
|
1747
|
+
streamState._rowState = rowState;
|
1748
|
+
streamState._rowID = _ref2;
|
1749
|
+
streamState._rowTag = rowTag;
|
1750
|
+
streamState._rowLength = rowLength;
|
1751
1751
|
return reader.read().then(progress).catch(error);
|
1752
1752
|
}
|
1753
1753
|
}
|
1754
1754
|
function error(e) {
|
1755
1755
|
reportGlobalError(response, e);
|
1756
1756
|
}
|
1757
|
-
var
|
1757
|
+
var streamState = {
|
1758
|
+
_rowState: 0,
|
1759
|
+
_rowID: 0,
|
1760
|
+
_rowTag: 0,
|
1761
|
+
_rowLength: 0,
|
1762
|
+
_buffer: []
|
1763
|
+
},
|
1764
|
+
reader = stream.getReader();
|
1758
1765
|
reader.read().then(progress).catch(error);
|
1759
1766
|
}
|
1760
1767
|
exports.createFromFetch = function (promiseForResponse, options) {
|
1761
1768
|
var response = createResponseFromOptions(options);
|
1762
1769
|
promiseForResponse.then(
|
1763
1770
|
function (r) {
|
1764
|
-
startReadingFromStream(response, r.body);
|
1771
|
+
startReadingFromStream(response, r.body, !1);
|
1765
1772
|
},
|
1766
1773
|
function (e) {
|
1767
1774
|
reportGlobalError(response, e);
|
@@ -1771,7 +1778,7 @@ exports.createFromFetch = function (promiseForResponse, options) {
|
|
1771
1778
|
};
|
1772
1779
|
exports.createFromReadableStream = function (stream, options) {
|
1773
1780
|
options = createResponseFromOptions(options);
|
1774
|
-
startReadingFromStream(options, stream);
|
1781
|
+
startReadingFromStream(options, stream, !1);
|
1775
1782
|
return getChunk(options, 0);
|
1776
1783
|
};
|
1777
1784
|
exports.createServerReference = function (id, callServer) {
|
@@ -1554,6 +1554,13 @@
|
|
1554
1554
|
map,
|
1555
1555
|
path
|
1556
1556
|
) {
|
1557
|
+
if (
|
1558
|
+
void 0 === response._debugChannel &&
|
1559
|
+
"pending" === referencedChunk.status &&
|
1560
|
+
parentObject[0] === REACT_ELEMENT_TYPE &&
|
1561
|
+
("4" === key || "5" === key)
|
1562
|
+
)
|
1563
|
+
return null;
|
1557
1564
|
if (initializingHandler) {
|
1558
1565
|
var handler = initializingHandler;
|
1559
1566
|
handler.deps++;
|
@@ -2067,8 +2074,6 @@
|
|
2067
2074
|
this._chunks = chunks;
|
2068
2075
|
this._stringDecoder = new TextDecoder();
|
2069
2076
|
this._fromJSON = null;
|
2070
|
-
this._rowLength = this._rowTag = this._rowID = this._rowState = 0;
|
2071
|
-
this._buffer = [];
|
2072
2077
|
this._closed = !1;
|
2073
2078
|
this._closedReason = null;
|
2074
2079
|
this._tempRefs = temporaryReferences;
|
@@ -2978,15 +2983,17 @@
|
|
2978
2983
|
void 0
|
2979
2984
|
)._weakResponse;
|
2980
2985
|
}
|
2981
|
-
function startReadingFromStream(response, stream) {
|
2986
|
+
function startReadingFromStream(response$jscomp$0, stream) {
|
2982
2987
|
function progress(_ref) {
|
2983
2988
|
var value = _ref.value;
|
2984
|
-
if (_ref.done)
|
2989
|
+
if (_ref.done)
|
2990
|
+
reportGlobalError(response$jscomp$0, Error("Connection closed."));
|
2985
2991
|
else {
|
2986
|
-
|
2987
|
-
|
2992
|
+
_ref = streamState;
|
2993
|
+
if (void 0 !== response$jscomp$0.weak.deref()) {
|
2988
2994
|
for (
|
2989
|
-
var
|
2995
|
+
var response = unwrapWeakResponse(response$jscomp$0),
|
2996
|
+
i = 0,
|
2990
2997
|
rowState = _ref._rowState,
|
2991
2998
|
rowID = _ref._rowID,
|
2992
2999
|
rowTag = _ref._rowTag,
|
@@ -3048,7 +3055,13 @@
|
|
3048
3055
|
var offset = value.byteOffset + i;
|
3049
3056
|
if (-1 < lastIdx)
|
3050
3057
|
(rowLength = new Uint8Array(value.buffer, offset, lastIdx - i)),
|
3051
|
-
processFullBinaryRow(
|
3058
|
+
processFullBinaryRow(
|
3059
|
+
response,
|
3060
|
+
rowID,
|
3061
|
+
rowTag,
|
3062
|
+
buffer,
|
3063
|
+
rowLength
|
3064
|
+
),
|
3052
3065
|
(i = lastIdx),
|
3053
3066
|
3 === rowState && i++,
|
3054
3067
|
(rowLength = rowID = rowTag = rowState = 0),
|
@@ -3073,9 +3086,16 @@
|
|
3073
3086
|
}
|
3074
3087
|
}
|
3075
3088
|
function error(e) {
|
3076
|
-
reportGlobalError(response, e);
|
3089
|
+
reportGlobalError(response$jscomp$0, e);
|
3077
3090
|
}
|
3078
|
-
var
|
3091
|
+
var streamState = {
|
3092
|
+
_rowState: 0,
|
3093
|
+
_rowID: 0,
|
3094
|
+
_rowTag: 0,
|
3095
|
+
_rowLength: 0,
|
3096
|
+
_buffer: []
|
3097
|
+
},
|
3098
|
+
reader = stream.getReader();
|
3079
3099
|
reader.read().then(progress).catch(error);
|
3080
3100
|
}
|
3081
3101
|
var ReactDOM = require("react-dom"),
|
@@ -1375,8 +1375,6 @@ function ResponseInstance(
|
|
1375
1375
|
this._chunks = chunks;
|
1376
1376
|
this._stringDecoder = new TextDecoder();
|
1377
1377
|
this._fromJSON = null;
|
1378
|
-
this._rowLength = this._rowTag = this._rowID = this._rowState = 0;
|
1379
|
-
this._buffer = [];
|
1380
1378
|
this._closed = !1;
|
1381
1379
|
this._closedReason = null;
|
1382
1380
|
this._tempRefs = temporaryReferences;
|
@@ -1857,12 +1855,12 @@ function startReadingFromStream(response, stream) {
|
|
1857
1855
|
if (_ref.done) reportGlobalError(response, Error("Connection closed."));
|
1858
1856
|
else {
|
1859
1857
|
var i = 0,
|
1860
|
-
rowState =
|
1861
|
-
_ref =
|
1858
|
+
rowState = streamState._rowState;
|
1859
|
+
_ref = streamState._rowID;
|
1862
1860
|
for (
|
1863
|
-
var rowTag =
|
1864
|
-
rowLength =
|
1865
|
-
buffer =
|
1861
|
+
var rowTag = streamState._rowTag,
|
1862
|
+
rowLength = streamState._rowLength,
|
1863
|
+
buffer = streamState._buffer,
|
1866
1864
|
chunkLength = value.length;
|
1867
1865
|
i < chunkLength;
|
1868
1866
|
|
@@ -1929,17 +1927,24 @@ function startReadingFromStream(response, stream) {
|
|
1929
1927
|
break;
|
1930
1928
|
}
|
1931
1929
|
}
|
1932
|
-
|
1933
|
-
|
1934
|
-
|
1935
|
-
|
1930
|
+
streamState._rowState = rowState;
|
1931
|
+
streamState._rowID = _ref;
|
1932
|
+
streamState._rowTag = rowTag;
|
1933
|
+
streamState._rowLength = rowLength;
|
1936
1934
|
return reader.read().then(progress).catch(error);
|
1937
1935
|
}
|
1938
1936
|
}
|
1939
1937
|
function error(e) {
|
1940
1938
|
reportGlobalError(response, e);
|
1941
1939
|
}
|
1942
|
-
var
|
1940
|
+
var streamState = {
|
1941
|
+
_rowState: 0,
|
1942
|
+
_rowID: 0,
|
1943
|
+
_rowTag: 0,
|
1944
|
+
_rowLength: 0,
|
1945
|
+
_buffer: []
|
1946
|
+
},
|
1947
|
+
reader = stream.getReader();
|
1943
1948
|
reader.read().then(progress).catch(error);
|
1944
1949
|
}
|
1945
1950
|
exports.createFromFetch = function (promiseForResponse, options) {
|