react-dom 19.0.0-rc-100dfd7dab-20240701 → 19.0.0-rc-3da26163a3-20240704

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.
@@ -223,7 +223,7 @@
223
223
  ),
224
224
  (currentView = new Uint8Array(2048)),
225
225
  (writtenBytes = 0)),
226
- writeToDestination(destination, textEncoder.encode(chunk));
226
+ writeToDestination(destination, chunk);
227
227
  else {
228
228
  var target = currentView;
229
229
  0 < writtenBytes && (target = currentView.subarray(writtenBytes));
@@ -3953,6 +3953,9 @@
3953
3953
  var JSCompiler_inline_result$jscomp$0 =
3954
3954
  describeNativeComponentFrame(componentStack.type, !0);
3955
3955
  info = JSCompiler_temp_const + JSCompiler_inline_result$jscomp$0;
3956
+ break;
3957
+ case 3:
3958
+ info += describeBuiltInComponentFrame(componentStack.type);
3956
3959
  }
3957
3960
  componentStack = componentStack.parent;
3958
3961
  } while (componentStack);
@@ -4052,7 +4055,6 @@
4052
4055
  abortSet,
4053
4056
  null,
4054
4057
  rootFormatContext,
4055
- emptyContextObject,
4056
4058
  null,
4057
4059
  emptyTreeContext,
4058
4060
  null,
@@ -4103,7 +4105,6 @@
4103
4105
  abortSet,
4104
4106
  keyPath,
4105
4107
  formatContext,
4106
- legacyContext,
4107
4108
  context,
4108
4109
  treeContext,
4109
4110
  componentStack,
@@ -4126,7 +4127,6 @@
4126
4127
  abortSet: abortSet,
4127
4128
  keyPath: keyPath,
4128
4129
  formatContext: formatContext,
4129
- legacyContext: legacyContext,
4130
4130
  context: context,
4131
4131
  treeContext: treeContext,
4132
4132
  componentStack: componentStack,
@@ -4147,7 +4147,6 @@
4147
4147
  abortSet,
4148
4148
  keyPath,
4149
4149
  formatContext,
4150
- legacyContext,
4151
4150
  context,
4152
4151
  treeContext,
4153
4152
  componentStack,
@@ -4171,7 +4170,6 @@
4171
4170
  abortSet: abortSet,
4172
4171
  keyPath: keyPath,
4173
4172
  formatContext: formatContext,
4174
- legacyContext: legacyContext,
4175
4173
  context: context,
4176
4174
  treeContext: treeContext,
4177
4175
  componentStack: componentStack,
@@ -4226,8 +4224,39 @@
4226
4224
  stack: stack
4227
4225
  };
4228
4226
  }
4229
- function getThrownInfo(request, node) {
4230
- return node ? { componentStack: getStackByComponentStackNode(node) } : {};
4227
+ function pushServerComponentStack(task, debugInfo) {
4228
+ if (null != debugInfo)
4229
+ for (var i = 0; i < debugInfo.length; i++) {
4230
+ var componentInfo = debugInfo[i];
4231
+ if ("string" === typeof componentInfo.name) {
4232
+ var name = componentInfo.name,
4233
+ env = componentInfo.env;
4234
+ env && (name += " (" + env + ")");
4235
+ task.componentStack = {
4236
+ tag: 3,
4237
+ parent: task.componentStack,
4238
+ type: name,
4239
+ owner: componentInfo.owner,
4240
+ stack: componentInfo.stack
4241
+ };
4242
+ }
4243
+ }
4244
+ }
4245
+ function getThrownInfo(node) {
4246
+ var errorInfo = {};
4247
+ node &&
4248
+ Object.defineProperty(errorInfo, "componentStack", {
4249
+ configurable: !0,
4250
+ enumerable: !0,
4251
+ get: function () {
4252
+ var stack = getStackByComponentStackNode(node);
4253
+ Object.defineProperty(errorInfo, "componentStack", {
4254
+ value: stack
4255
+ });
4256
+ return stack;
4257
+ }
4258
+ });
4259
+ return errorInfo;
4231
4260
  }
4232
4261
  function encodeErrorForBoundary(
4233
4262
  boundary,
@@ -4252,19 +4281,20 @@
4252
4281
  boundary.errorComponentStack = thrownInfo.componentStack;
4253
4282
  }
4254
4283
  function logRecoverableError(request, error$1, errorInfo) {
4255
- request = request.onError(error$1, errorInfo);
4256
- if (null != request && "string" !== typeof request)
4284
+ request = request.onError;
4285
+ error$1 = request(error$1, errorInfo);
4286
+ if (null != error$1 && "string" !== typeof error$1)
4257
4287
  error$jscomp$2(
4258
4288
  'onError returned something with a type other than "string". onError should return a string and may return null or undefined but must not return anything else. It received something of type "%s" instead',
4259
- typeof request
4289
+ typeof error$1
4260
4290
  );
4261
- else return request;
4291
+ else return error$1;
4262
4292
  }
4263
4293
  function fatalError(request, error) {
4264
- var onShellError = request.onShellError;
4265
- onShellError(error);
4266
- onShellError = request.onFatalError;
4294
+ var onShellError = request.onShellError,
4295
+ onFatalError = request.onFatalError;
4267
4296
  onShellError(error);
4297
+ onFatalError(error);
4268
4298
  null !== request.destination
4269
4299
  ? ((request.status = 2), request.destination.destroy(error))
4270
4300
  : ((request.status = 1), (request.fatalError = error));
@@ -4990,7 +5020,7 @@
4990
5020
  } catch (error$2) {
4991
5021
  contentRootSegment.status = 4;
4992
5022
  newBoundary.status = CLIENT_RENDERED;
4993
- var thrownInfo = getThrownInfo(request, task.componentStack);
5023
+ var thrownInfo = getThrownInfo(task.componentStack);
4994
5024
  var errorDigest = logRecoverableError(
4995
5025
  request,
4996
5026
  error$2,
@@ -5044,7 +5074,6 @@
5044
5074
  fallbackAbortSet,
5045
5075
  fallbackKeyPath,
5046
5076
  task.formatContext,
5047
- task.legacyContext,
5048
5077
  task.context,
5049
5078
  task.treeContext,
5050
5079
  suspenseComponentStack,
@@ -5247,197 +5276,194 @@
5247
5276
  props = node$jscomp$0.props,
5248
5277
  refProp = props.ref;
5249
5278
  var ref = void 0 !== refProp ? refProp : null;
5250
- refProp = node$jscomp$0._owner;
5279
+ var owner = node$jscomp$0._owner;
5280
+ refProp = task.componentStack;
5281
+ pushServerComponentStack(task, node$jscomp$0._debugInfo);
5251
5282
  var name = getComponentNameFromType(type),
5252
5283
  keyOrIndex =
5253
5284
  null == key ? (-1 === childIndex ? 0 : childIndex) : key;
5254
5285
  key = [task.keyPath, name, keyOrIndex];
5255
- if (null !== task.replay)
5256
- a: {
5257
- var replay = task.replay;
5258
- childIndex = replay.nodes;
5259
- for (
5260
- node$jscomp$0 = 0;
5261
- node$jscomp$0 < childIndex.length;
5262
- node$jscomp$0++
5263
- ) {
5264
- var node = childIndex[node$jscomp$0];
5265
- if (keyOrIndex === node[1]) {
5266
- if (4 === node.length) {
5267
- if (null !== name && name !== node[0])
5286
+ if (null !== task.replay) {
5287
+ var replay = task.replay;
5288
+ node$jscomp$0 = replay.nodes;
5289
+ for (
5290
+ childIndex = 0;
5291
+ childIndex < node$jscomp$0.length;
5292
+ childIndex++
5293
+ ) {
5294
+ var node = node$jscomp$0[childIndex];
5295
+ if (keyOrIndex === node[1]) {
5296
+ if (4 === node.length) {
5297
+ if (null !== name && name !== node[0])
5298
+ throw Error(
5299
+ "Expected the resume to render <" +
5300
+ node[0] +
5301
+ "> in this slot but instead it rendered <" +
5302
+ name +
5303
+ ">. The tree doesn't match so React will fallback to client rendering."
5304
+ );
5305
+ var childNodes = node[2];
5306
+ name = node[3];
5307
+ keyOrIndex = task.node;
5308
+ task.replay = {
5309
+ nodes: childNodes,
5310
+ slots: name,
5311
+ pendingTasks: 1
5312
+ };
5313
+ try {
5314
+ renderElement(
5315
+ request,
5316
+ task,
5317
+ key,
5318
+ type,
5319
+ props,
5320
+ ref,
5321
+ owner,
5322
+ null
5323
+ );
5324
+ if (
5325
+ 1 === task.replay.pendingTasks &&
5326
+ 0 < task.replay.nodes.length
5327
+ )
5268
5328
  throw Error(
5269
- "Expected the resume to render <" +
5270
- node[0] +
5271
- "> in this slot but instead it rendered <" +
5272
- name +
5273
- ">. The tree doesn't match so React will fallback to client rendering."
5329
+ "Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering."
5274
5330
  );
5275
- var childNodes = node[2];
5331
+ task.replay.pendingTasks--;
5332
+ } catch (x) {
5333
+ if (
5334
+ "object" === typeof x &&
5335
+ null !== x &&
5336
+ (x === SuspenseException ||
5337
+ "function" === typeof x.then)
5338
+ )
5339
+ throw (
5340
+ (task.node === keyOrIndex && (task.replay = replay),
5341
+ x)
5342
+ );
5343
+ task.replay.pendingTasks--;
5344
+ owner = getThrownInfo(task.componentStack);
5345
+ erroredReplay(
5346
+ request,
5347
+ task.blockedBoundary,
5348
+ x,
5349
+ owner,
5350
+ childNodes,
5351
+ name
5352
+ );
5353
+ }
5354
+ task.replay = replay;
5355
+ } else {
5356
+ if (type !== REACT_SUSPENSE_TYPE)
5357
+ throw Error(
5358
+ "Expected the resume to render <Suspense> in this slot but instead it rendered <" +
5359
+ (getComponentNameFromType(type) || "Unknown") +
5360
+ ">. The tree doesn't match so React will fallback to client rendering."
5361
+ );
5362
+ a: {
5363
+ type = void 0;
5364
+ ref = task;
5365
+ var props$jscomp$0 = props;
5366
+ props = node[5];
5367
+ replay = node[2];
5276
5368
  name = node[3];
5277
- node = task.node;
5278
- task.replay = {
5279
- nodes: childNodes,
5369
+ keyOrIndex = null === node[4] ? [] : node[4][2];
5370
+ node = null === node[4] ? null : node[4][3];
5371
+ var previousComponentStack = ref.componentStack;
5372
+ owner = ref.componentStack =
5373
+ createBuiltInComponentStack(
5374
+ ref,
5375
+ "Suspense",
5376
+ owner,
5377
+ null
5378
+ );
5379
+ var prevKeyPath = ref.keyPath,
5380
+ previousReplaySet = ref.replay,
5381
+ parentBoundary = ref.blockedBoundary,
5382
+ parentHoistableState = ref.hoistableState,
5383
+ content = props$jscomp$0.children;
5384
+ props$jscomp$0 = props$jscomp$0.fallback;
5385
+ var fallbackAbortSet = new Set(),
5386
+ resumedBoundary = createSuspenseBoundary(
5387
+ request,
5388
+ fallbackAbortSet
5389
+ );
5390
+ resumedBoundary.parentFlushed = !0;
5391
+ resumedBoundary.rootSegmentID = props;
5392
+ ref.blockedBoundary = resumedBoundary;
5393
+ ref.hoistableState = resumedBoundary.contentState;
5394
+ ref.replay = {
5395
+ nodes: replay,
5280
5396
  slots: name,
5281
5397
  pendingTasks: 1
5282
5398
  };
5283
5399
  try {
5284
- renderElement(
5285
- request,
5286
- task,
5287
- key,
5288
- type,
5289
- props,
5290
- ref,
5291
- refProp,
5292
- null
5293
- );
5400
+ renderNode(request, ref, content, -1);
5294
5401
  if (
5295
- 1 === task.replay.pendingTasks &&
5296
- 0 < task.replay.nodes.length
5402
+ 1 === ref.replay.pendingTasks &&
5403
+ 0 < ref.replay.nodes.length
5297
5404
  )
5298
5405
  throw Error(
5299
5406
  "Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering."
5300
5407
  );
5301
- task.replay.pendingTasks--;
5302
- } catch (x) {
5408
+ ref.replay.pendingTasks--;
5303
5409
  if (
5304
- "object" === typeof x &&
5305
- null !== x &&
5306
- (x === SuspenseException ||
5307
- "function" === typeof x.then)
5308
- )
5309
- throw (
5310
- (task.node === node && (task.replay = replay), x)
5311
- );
5312
- task.replay.pendingTasks--;
5313
- refProp = getThrownInfo(request, task.componentStack);
5314
- erroredReplay(
5315
- request,
5316
- task.blockedBoundary,
5317
- x,
5318
- refProp,
5319
- childNodes,
5320
- name
5321
- );
5322
- }
5323
- task.replay = replay;
5324
- } else {
5325
- if (type !== REACT_SUSPENSE_TYPE)
5326
- throw Error(
5327
- "Expected the resume to render <Suspense> in this slot but instead it rendered <" +
5328
- (getComponentNameFromType(type) || "Unknown") +
5329
- ">. The tree doesn't match so React will fallback to client rendering."
5330
- );
5331
- b: {
5332
- type = void 0;
5333
- ref = key;
5334
- var props$jscomp$0 = props;
5335
- props = node[5];
5336
- key = node[2];
5337
- replay = node[3];
5338
- name = null === node[4] ? [] : node[4][2];
5339
- node = null === node[4] ? null : node[4][3];
5340
- keyOrIndex = task.componentStack;
5341
- refProp = task.componentStack =
5342
- createBuiltInComponentStack(
5343
- task,
5344
- "Suspense",
5345
- refProp,
5346
- null
5347
- );
5348
- var prevKeyPath = task.keyPath,
5349
- previousReplaySet = task.replay,
5350
- parentBoundary = task.blockedBoundary,
5351
- parentHoistableState = task.hoistableState,
5352
- content = props$jscomp$0.children;
5353
- props$jscomp$0 = props$jscomp$0.fallback;
5354
- var fallbackAbortSet = new Set(),
5355
- resumedBoundary = createSuspenseBoundary(
5410
+ 0 === resumedBoundary.pendingTasks &&
5411
+ resumedBoundary.status === PENDING
5412
+ ) {
5413
+ resumedBoundary.status = COMPLETED;
5414
+ request.completedBoundaries.push(resumedBoundary);
5415
+ break a;
5416
+ }
5417
+ } catch (error$3) {
5418
+ (resumedBoundary.status = CLIENT_RENDERED),
5419
+ (childNodes = getThrownInfo(ref.componentStack)),
5420
+ (type = logRecoverableError(
5356
5421
  request,
5357
- fallbackAbortSet
5422
+ error$3,
5423
+ childNodes
5424
+ )),
5425
+ encodeErrorForBoundary(
5426
+ resumedBoundary,
5427
+ type,
5428
+ error$3,
5429
+ childNodes,
5430
+ !1
5431
+ ),
5432
+ ref.replay.pendingTasks--,
5433
+ request.clientRenderedBoundaries.push(
5434
+ resumedBoundary
5358
5435
  );
5359
- resumedBoundary.parentFlushed = !0;
5360
- resumedBoundary.rootSegmentID = props;
5361
- task.blockedBoundary = resumedBoundary;
5362
- task.hoistableState = resumedBoundary.contentState;
5363
- task.replay = {
5364
- nodes: key,
5365
- slots: replay,
5366
- pendingTasks: 1
5367
- };
5368
- try {
5369
- renderNode(request, task, content, -1);
5370
- if (
5371
- 1 === task.replay.pendingTasks &&
5372
- 0 < task.replay.nodes.length
5373
- )
5374
- throw Error(
5375
- "Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering."
5376
- );
5377
- task.replay.pendingTasks--;
5378
- if (
5379
- 0 === resumedBoundary.pendingTasks &&
5380
- resumedBoundary.status === PENDING
5381
- ) {
5382
- resumedBoundary.status = COMPLETED;
5383
- request.completedBoundaries.push(resumedBoundary);
5384
- break b;
5385
- }
5386
- } catch (error$3) {
5387
- (resumedBoundary.status = CLIENT_RENDERED),
5388
- (childNodes = getThrownInfo(
5389
- request,
5390
- task.componentStack
5391
- )),
5392
- (type = logRecoverableError(
5393
- request,
5394
- error$3,
5395
- childNodes
5396
- )),
5397
- encodeErrorForBoundary(
5398
- resumedBoundary,
5399
- type,
5400
- error$3,
5401
- childNodes,
5402
- !1
5403
- ),
5404
- task.replay.pendingTasks--,
5405
- request.clientRenderedBoundaries.push(
5406
- resumedBoundary
5407
- );
5408
- } finally {
5409
- (task.blockedBoundary = parentBoundary),
5410
- (task.hoistableState = parentHoistableState),
5411
- (task.replay = previousReplaySet),
5412
- (task.keyPath = prevKeyPath),
5413
- (task.componentStack = keyOrIndex);
5414
- }
5415
- childNodes = createReplayTask(
5416
- request,
5417
- null,
5418
- { nodes: name, slots: node, pendingTasks: 0 },
5419
- props$jscomp$0,
5420
- -1,
5421
- parentBoundary,
5422
- resumedBoundary.fallbackState,
5423
- fallbackAbortSet,
5424
- [ref[0], "Suspense Fallback", ref[2]],
5425
- task.formatContext,
5426
- task.legacyContext,
5427
- task.context,
5428
- task.treeContext,
5429
- refProp,
5430
- !0
5431
- );
5432
- request.pingedTasks.push(childNodes);
5436
+ } finally {
5437
+ (ref.blockedBoundary = parentBoundary),
5438
+ (ref.hoistableState = parentHoistableState),
5439
+ (ref.replay = previousReplaySet),
5440
+ (ref.keyPath = prevKeyPath),
5441
+ (ref.componentStack = previousComponentStack);
5433
5442
  }
5443
+ childNodes = createReplayTask(
5444
+ request,
5445
+ null,
5446
+ { nodes: keyOrIndex, slots: node, pendingTasks: 0 },
5447
+ props$jscomp$0,
5448
+ -1,
5449
+ parentBoundary,
5450
+ resumedBoundary.fallbackState,
5451
+ fallbackAbortSet,
5452
+ [key[0], "Suspense Fallback", key[2]],
5453
+ ref.formatContext,
5454
+ ref.context,
5455
+ ref.treeContext,
5456
+ owner,
5457
+ !0
5458
+ );
5459
+ request.pingedTasks.push(childNodes);
5434
5460
  }
5435
- childIndex.splice(node$jscomp$0, 1);
5436
- break a;
5437
5461
  }
5462
+ node$jscomp$0.splice(childIndex, 1);
5463
+ break;
5438
5464
  }
5439
5465
  }
5440
- else
5466
+ } else
5441
5467
  renderElement(
5442
5468
  request,
5443
5469
  task,
@@ -5445,24 +5471,27 @@
5445
5471
  type,
5446
5472
  props,
5447
5473
  ref,
5448
- refProp,
5474
+ owner,
5449
5475
  null
5450
5476
  );
5477
+ task.componentStack = refProp;
5451
5478
  return;
5452
5479
  case REACT_PORTAL_TYPE:
5453
5480
  throw Error(
5454
5481
  "Portals are not currently supported by the server renderer. Render them conditionally so that they only appear on the client render."
5455
5482
  );
5456
5483
  case REACT_LAZY_TYPE:
5457
- childNodes = task.componentStack;
5458
- task.componentStack = createBuiltInComponentStack(
5459
- task,
5460
- "Lazy",
5461
- null,
5462
- null
5463
- );
5484
+ refProp = task.componentStack;
5485
+ pushServerComponentStack(task, node$jscomp$0._debugInfo);
5486
+ task.componentStack === refProp &&
5487
+ (task.componentStack = createBuiltInComponentStack(
5488
+ task,
5489
+ "Lazy",
5490
+ null,
5491
+ null
5492
+ ));
5464
5493
  node$jscomp$0 = callLazyInitInDEV(node$jscomp$0);
5465
- task.componentStack = childNodes;
5494
+ task.componentStack = refProp;
5466
5495
  renderNodeDestructive(request, task, node$jscomp$0, childIndex);
5467
5496
  return;
5468
5497
  }
@@ -5471,22 +5500,21 @@
5471
5500
  return;
5472
5501
  }
5473
5502
  null === node$jscomp$0 || "object" !== typeof node$jscomp$0
5474
- ? (refProp = null)
5475
- : ((childNodes =
5503
+ ? (childNodes = null)
5504
+ : ((refProp =
5476
5505
  (MAYBE_ITERATOR_SYMBOL &&
5477
5506
  node$jscomp$0[MAYBE_ITERATOR_SYMBOL]) ||
5478
5507
  node$jscomp$0["@@iterator"]),
5479
- (refProp = "function" === typeof childNodes ? childNodes : null));
5480
- if (refProp && (childNodes = refProp.call(node$jscomp$0))) {
5481
- if (childNodes === node$jscomp$0) {
5508
+ (childNodes = "function" === typeof refProp ? refProp : null));
5509
+ if (childNodes && (refProp = childNodes.call(node$jscomp$0))) {
5510
+ if (refProp === node$jscomp$0) {
5482
5511
  if (
5483
5512
  -1 !== childIndex ||
5484
5513
  null === task.componentStack ||
5485
5514
  1 !== task.componentStack.tag ||
5486
5515
  "[object GeneratorFunction]" !==
5487
5516
  Object.prototype.toString.call(task.componentStack.type) ||
5488
- "[object Generator]" !==
5489
- Object.prototype.toString.call(childNodes)
5517
+ "[object Generator]" !== Object.prototype.toString.call(refProp)
5490
5518
  )
5491
5519
  didWarnAboutGenerators ||
5492
5520
  error$jscomp$2(
@@ -5494,32 +5522,36 @@
5494
5522
  ),
5495
5523
  (didWarnAboutGenerators = !0);
5496
5524
  } else
5497
- node$jscomp$0.entries !== refProp ||
5525
+ node$jscomp$0.entries !== childNodes ||
5498
5526
  didWarnAboutMaps ||
5499
5527
  (error$jscomp$2(
5500
5528
  "Using Maps as children is not supported. Use an array of keyed ReactElements instead."
5501
5529
  ),
5502
5530
  (didWarnAboutMaps = !0));
5503
- node$jscomp$0 = childNodes.next();
5531
+ node$jscomp$0 = refProp.next();
5504
5532
  if (!node$jscomp$0.done) {
5505
- refProp = [];
5533
+ childNodes = [];
5506
5534
  do
5507
- refProp.push(node$jscomp$0.value),
5508
- (node$jscomp$0 = childNodes.next());
5535
+ childNodes.push(node$jscomp$0.value),
5536
+ (node$jscomp$0 = refProp.next());
5509
5537
  while (!node$jscomp$0.done);
5510
- renderChildrenArray(request, task, refProp, childIndex);
5538
+ renderChildrenArray(request, task, childNodes, childIndex);
5511
5539
  }
5512
5540
  return;
5513
5541
  }
5514
5542
  if ("function" === typeof node$jscomp$0.then)
5515
5543
  return (
5516
5544
  (task.thenableState = null),
5517
- renderNodeDestructive(
5545
+ (refProp = task.componentStack),
5546
+ pushServerComponentStack(task, node$jscomp$0._debugInfo),
5547
+ (node$jscomp$0 = renderNodeDestructive(
5518
5548
  request,
5519
5549
  task,
5520
5550
  unwrapThenable(node$jscomp$0),
5521
5551
  childIndex
5522
- )
5552
+ )),
5553
+ (task.componentStack = refProp),
5554
+ node$jscomp$0
5523
5555
  );
5524
5556
  if (node$jscomp$0.$$typeof === REACT_CONTEXT_TYPE)
5525
5557
  return renderNodeDestructive(
@@ -5528,43 +5560,43 @@
5528
5560
  node$jscomp$0._currentValue,
5529
5561
  childIndex
5530
5562
  );
5531
- childIndex = Object.prototype.toString.call(node$jscomp$0);
5563
+ task = Object.prototype.toString.call(node$jscomp$0);
5532
5564
  throw Error(
5533
5565
  "Objects are not valid as a React child (found: " +
5534
- ("[object Object]" === childIndex
5566
+ ("[object Object]" === task
5535
5567
  ? "object with keys {" +
5536
5568
  Object.keys(node$jscomp$0).join(", ") +
5537
5569
  "}"
5538
- : childIndex) +
5570
+ : task) +
5539
5571
  "). If you meant to render a collection of children, use an array instead."
5540
5572
  );
5541
5573
  }
5542
5574
  "string" === typeof node$jscomp$0
5543
- ? ((childIndex = task.blockedSegment),
5544
- null !== childIndex &&
5545
- (childIndex.lastPushedText = pushTextInstance(
5546
- childIndex.chunks,
5575
+ ? ((task = task.blockedSegment),
5576
+ null !== task &&
5577
+ (task.lastPushedText = pushTextInstance(
5578
+ task.chunks,
5547
5579
  node$jscomp$0,
5548
5580
  request.renderState,
5549
- childIndex.lastPushedText
5581
+ task.lastPushedText
5550
5582
  )))
5551
5583
  : "number" === typeof node$jscomp$0 ||
5552
5584
  "bigint" === typeof node$jscomp$0
5553
- ? ((childIndex = task.blockedSegment),
5554
- null !== childIndex &&
5555
- (childIndex.lastPushedText = pushTextInstance(
5556
- childIndex.chunks,
5585
+ ? ((task = task.blockedSegment),
5586
+ null !== task &&
5587
+ (task.lastPushedText = pushTextInstance(
5588
+ task.chunks,
5557
5589
  "" + node$jscomp$0,
5558
5590
  request.renderState,
5559
- childIndex.lastPushedText
5591
+ task.lastPushedText
5560
5592
  )))
5561
5593
  : ("function" === typeof node$jscomp$0 &&
5562
- ((childIndex =
5594
+ ((task =
5563
5595
  node$jscomp$0.displayName || node$jscomp$0.name || "Component"),
5564
5596
  error$jscomp$2(
5565
5597
  "Functions are not valid as a React child. This may happen if you return %s instead of <%s /> from render. Or maybe you meant to call this function rather than return it.",
5566
- childIndex,
5567
- childIndex
5598
+ task,
5599
+ task
5568
5600
  )),
5569
5601
  "symbol" === typeof node$jscomp$0 &&
5570
5602
  error$jscomp$2(
@@ -5574,7 +5606,9 @@
5574
5606
  }
5575
5607
  }
5576
5608
  function renderChildrenArray(request$jscomp$0, task, children, childIndex) {
5577
- var prevKeyPath = task.keyPath;
5609
+ var prevKeyPath = task.keyPath,
5610
+ previousComponentStack = task.componentStack;
5611
+ pushServerComponentStack(task, task.node._debugInfo);
5578
5612
  if (
5579
5613
  -1 !== childIndex &&
5580
5614
  ((task.keyPath = [task.keyPath, "Fragment", childIndex]),
@@ -5608,7 +5642,7 @@
5608
5642
  )
5609
5643
  throw x;
5610
5644
  task.replay.pendingTasks--;
5611
- children = getThrownInfo(request$jscomp$0, task.componentStack);
5645
+ children = getThrownInfo(task.componentStack);
5612
5646
  erroredReplay(
5613
5647
  request$jscomp$0,
5614
5648
  task.blockedBoundary,
@@ -5624,6 +5658,7 @@
5624
5658
  }
5625
5659
  }
5626
5660
  task.keyPath = prevKeyPath;
5661
+ task.componentStack = previousComponentStack;
5627
5662
  return;
5628
5663
  }
5629
5664
  replay = task.treeContext;
@@ -5649,6 +5684,7 @@
5649
5684
  }
5650
5685
  task.treeContext = replay;
5651
5686
  task.keyPath = prevKeyPath;
5687
+ task.componentStack = previousComponentStack;
5652
5688
  return;
5653
5689
  }
5654
5690
  for (j = 0; j < replayNodes; j++) {
@@ -5742,6 +5778,7 @@
5742
5778
  }
5743
5779
  task.treeContext = replay;
5744
5780
  task.keyPath = prevKeyPath;
5781
+ task.componentStack = previousComponentStack;
5745
5782
  }
5746
5783
  function untrackBoundary(request, boundary) {
5747
5784
  request = request.trackedPostpones;
@@ -5754,7 +5791,6 @@
5754
5791
  }
5755
5792
  function renderNode(request, task, node, childIndex) {
5756
5793
  var previousFormatContext = task.formatContext,
5757
- previousLegacyContext = task.legacyContext,
5758
5794
  previousContext = task.context,
5759
5795
  previousKeyPath = task.keyPath,
5760
5796
  previousTreeContext = task.treeContext,
@@ -5786,7 +5822,6 @@
5786
5822
  task.abortSet,
5787
5823
  task.keyPath,
5788
5824
  task.formatContext,
5789
- task.legacyContext,
5790
5825
  task.context,
5791
5826
  task.treeContext,
5792
5827
  null !== task.componentStack ? task.componentStack.parent : null,
@@ -5794,7 +5829,6 @@
5794
5829
  ).ping;
5795
5830
  node.then(request, request);
5796
5831
  task.formatContext = previousFormatContext;
5797
- task.legacyContext = previousLegacyContext;
5798
5832
  task.context = previousContext;
5799
5833
  task.keyPath = previousKeyPath;
5800
5834
  task.treeContext = previousTreeContext;
@@ -5844,7 +5878,6 @@
5844
5878
  task.abortSet,
5845
5879
  task.keyPath,
5846
5880
  task.formatContext,
5847
- task.legacyContext,
5848
5881
  task.context,
5849
5882
  task.treeContext,
5850
5883
  null !== task.componentStack ? task.componentStack.parent : null,
@@ -5852,7 +5885,6 @@
5852
5885
  ).ping;
5853
5886
  node.then(request, request);
5854
5887
  task.formatContext = previousFormatContext;
5855
- task.legacyContext = previousLegacyContext;
5856
5888
  task.context = previousContext;
5857
5889
  task.keyPath = previousKeyPath;
5858
5890
  task.treeContext = previousTreeContext;
@@ -5863,7 +5895,6 @@
5863
5895
  }
5864
5896
  }
5865
5897
  task.formatContext = previousFormatContext;
5866
- task.legacyContext = previousLegacyContext;
5867
5898
  task.context = previousContext;
5868
5899
  task.keyPath = previousKeyPath;
5869
5900
  task.treeContext = previousTreeContext;
@@ -5994,7 +6025,7 @@
5994
6025
  boundary.pendingTasks--,
5995
6026
  boundary.status !== CLIENT_RENDERED &&
5996
6027
  ((boundary.status = CLIENT_RENDERED),
5997
- (task = getThrownInfo(request, task.componentStack)),
6028
+ (task = getThrownInfo(task.componentStack)),
5998
6029
  (segment = logRecoverableError(request, error, task)),
5999
6030
  encodeErrorForBoundary(boundary, segment, error, task, !0),
6000
6031
  untrackBoundary(request, boundary),
@@ -6205,10 +6236,7 @@
6205
6236
  } else {
6206
6237
  request.replay.pendingTasks--;
6207
6238
  request.abortSet.delete(request);
6208
- var errorInfo = getThrownInfo(
6209
- request$jscomp$0,
6210
- request.componentStack
6211
- );
6239
+ var errorInfo = getThrownInfo(request.componentStack);
6212
6240
  erroredReplay(
6213
6241
  request$jscomp$0,
6214
6242
  request.blockedBoundary,
@@ -6277,7 +6305,6 @@
6277
6305
  task$jscomp$0.componentStack.parent);
6278
6306
  } else {
6279
6307
  var errorInfo$jscomp$0 = getThrownInfo(
6280
- request,
6281
6308
  task$jscomp$0.componentStack
6282
6309
  );
6283
6310
  task$jscomp$0.abortSet.delete(task$jscomp$0);
@@ -8638,11 +8665,11 @@
8638
8665
  didWarnAboutMaps = !1;
8639
8666
  (function () {
8640
8667
  var isomorphicReactPackageVersion = React.version;
8641
- if ("19.0.0-rc-100dfd7dab-20240701" !== isomorphicReactPackageVersion)
8668
+ if ("19.0.0-rc-3da26163a3-20240704" !== isomorphicReactPackageVersion)
8642
8669
  throw Error(
8643
8670
  'Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:\n - react: ' +
8644
8671
  (isomorphicReactPackageVersion +
8645
- "\n - react-dom: 19.0.0-rc-100dfd7dab-20240701\nLearn more: https://react.dev/warnings/version-mismatch")
8672
+ "\n - react-dom: 19.0.0-rc-3da26163a3-20240704\nLearn more: https://react.dev/warnings/version-mismatch")
8646
8673
  );
8647
8674
  })();
8648
8675
  exports.renderToPipeableStream = function (children, options) {
@@ -8684,5 +8711,5 @@
8684
8711
  }
8685
8712
  };
8686
8713
  };
8687
- exports.version = "19.0.0-rc-100dfd7dab-20240701";
8714
+ exports.version = "19.0.0-rc-3da26163a3-20240704";
8688
8715
  })();