react-server-dom-webpack 19.0.0-rc-935180c7e0-20240524 → 19.0.0-rc-38e3b23483-20240529

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.
@@ -417,7 +417,7 @@ function error(format) {
417
417
  printWarning('error', format, args);
418
418
  }
419
419
  }
420
- }
420
+ } // eslint-disable-next-line react-internal/no-production-logging
421
421
 
422
422
  function printWarning(level, format, args) {
423
423
  // When changing this logic, you might want to also
@@ -426,6 +426,9 @@ function printWarning(level, format, args) {
426
426
  var isErrorLogger = format === '%s\n\n%s\n' || format === '%o\n\n%s\n\n%s\n';
427
427
 
428
428
  if (ReactSharedInternals.getCurrentStack) {
429
+ // We only add the current stack to the console when createTask is not supported.
430
+ // Since createTask requires DevTools to be open to work, this means that stacks
431
+ // can be lost while DevTools isn't open but we can't detect this.
429
432
  var stack = ReactSharedInternals.getCurrentStack();
430
433
 
431
434
  if (stack !== '') {
@@ -436,7 +436,7 @@ function error(format) {
436
436
  printWarning('error', format, args);
437
437
  }
438
438
  }
439
- }
439
+ } // eslint-disable-next-line react-internal/no-production-logging
440
440
 
441
441
  function printWarning(level, format, args) {
442
442
  // When changing this logic, you might want to also
@@ -445,6 +445,9 @@ function printWarning(level, format, args) {
445
445
  var isErrorLogger = format === '%s\n\n%s\n' || format === '%o\n\n%s\n\n%s\n';
446
446
 
447
447
  if (ReactSharedInternals.getCurrentStack) {
448
+ // We only add the current stack to the console when createTask is not supported.
449
+ // Since createTask requires DevTools to be open to work, this means that stacks
450
+ // can be lost while DevTools isn't open but we can't detect this.
448
451
  var stack = ReactSharedInternals.getCurrentStack();
449
452
 
450
453
  if (stack !== '') {
@@ -437,7 +437,7 @@ function error(format) {
437
437
  printWarning('error', format, args);
438
438
  }
439
439
  }
440
- }
440
+ } // eslint-disable-next-line react-internal/no-production-logging
441
441
 
442
442
  function printWarning(level, format, args) {
443
443
  // When changing this logic, you might want to also
@@ -446,6 +446,9 @@ function printWarning(level, format, args) {
446
446
  var isErrorLogger = format === '%s\n\n%s\n' || format === '%o\n\n%s\n\n%s\n';
447
447
 
448
448
  if (ReactSharedInternals.getCurrentStack) {
449
+ // We only add the current stack to the console when createTask is not supported.
450
+ // Since createTask requires DevTools to be open to work, this means that stacks
451
+ // can be lost while DevTools isn't open but we can't detect this.
449
452
  var stack = ReactSharedInternals.getCurrentStack();
450
453
 
451
454
  if (stack !== '') {
@@ -390,7 +390,7 @@ function error(format) {
390
390
  printWarning('error', format, args);
391
391
  }
392
392
  }
393
- }
393
+ } // eslint-disable-next-line react-internal/no-production-logging
394
394
 
395
395
  function printWarning(level, format, args) {
396
396
  // When changing this logic, you might want to also
@@ -399,6 +399,9 @@ function printWarning(level, format, args) {
399
399
  var isErrorLogger = format === '%s\n\n%s\n' || format === '%o\n\n%s\n\n%s\n';
400
400
 
401
401
  if (ReactSharedInternals.getCurrentStack) {
402
+ // We only add the current stack to the console when createTask is not supported.
403
+ // Since createTask requires DevTools to be open to work, this means that stacks
404
+ // can be lost while DevTools isn't open but we can't detect this.
402
405
  var stack = ReactSharedInternals.getCurrentStack();
403
406
 
404
407
  if (stack !== '') {
@@ -39,6 +39,9 @@ if (!ReactSharedInternalsServer) {
39
39
  throw new Error('The "react" package in this environment is not configured correctly. ' + 'The "react-server" condition must be enabled in any environment that ' + 'runs React Server Components.');
40
40
  }
41
41
 
42
+ // -----------------------------------------------------------------------------
43
+ var enablePostpone = false;
44
+
42
45
  function error(format) {
43
46
  {
44
47
  {
@@ -49,7 +52,7 @@ function error(format) {
49
52
  printWarning('error', format, args);
50
53
  }
51
54
  }
52
- }
55
+ } // eslint-disable-next-line react-internal/no-production-logging
53
56
 
54
57
  function printWarning(level, format, args) {
55
58
  // When changing this logic, you might want to also
@@ -58,6 +61,9 @@ function printWarning(level, format, args) {
58
61
  var isErrorLogger = format === '%s\n\n%s\n' || format === '%o\n\n%s\n\n%s\n';
59
62
 
60
63
  if (ReactSharedInternalsServer.getCurrentStack) {
64
+ // We only add the current stack to the console when createTask is not supported.
65
+ // Since createTask requires DevTools to be open to work, this means that stacks
66
+ // can be lost while DevTools isn't open but we can't detect this.
61
67
  var stack = ReactSharedInternalsServer.getCurrentStack();
62
68
 
63
69
  if (stack !== '') {
@@ -88,9 +94,6 @@ function printWarning(level, format, args) {
88
94
  }
89
95
  }
90
96
 
91
- // -----------------------------------------------------------------------------
92
- var enablePostpone = false;
93
-
94
97
  function scheduleWork(callback) {
95
98
  callback();
96
99
  }
@@ -2008,7 +2011,7 @@ validated) // DEV-only
2008
2011
  result = callComponentInDEV(Component, props, componentDebugInfo);
2009
2012
  }
2010
2013
 
2011
- if (typeof result === 'object' && result !== null) {
2014
+ if (typeof result === 'object' && result !== null && !isClientReference(result)) {
2012
2015
  if (typeof result.then === 'function') {
2013
2016
  // When the return value is in children position we can resolve it immediately,
2014
2017
  // to its value without a wrapper if it's synchronously available.
@@ -932,7 +932,11 @@ function renderFunctionComponent(request, task, key, Component, props) {
932
932
  thenableIndexCounter = 0;
933
933
  thenableState = prevThenableState;
934
934
  Component = Component(props, void 0);
935
- if ("object" === typeof Component && null !== Component) {
935
+ if (
936
+ "object" === typeof Component &&
937
+ null !== Component &&
938
+ Component.$$typeof !== CLIENT_REFERENCE_TAG$1
939
+ ) {
936
940
  if ("function" === typeof Component.then) {
937
941
  props = Component;
938
942
  if ("fulfilled" === props.status) return props.value;
@@ -39,6 +39,9 @@ if (!ReactSharedInternalsServer) {
39
39
  throw new Error('The "react" package in this environment is not configured correctly. ' + 'The "react-server" condition must be enabled in any environment that ' + 'runs React Server Components.');
40
40
  }
41
41
 
42
+ // -----------------------------------------------------------------------------
43
+ var enablePostpone = false;
44
+
42
45
  function error(format) {
43
46
  {
44
47
  {
@@ -49,7 +52,7 @@ function error(format) {
49
52
  printWarning('error', format, args);
50
53
  }
51
54
  }
52
- }
55
+ } // eslint-disable-next-line react-internal/no-production-logging
53
56
 
54
57
  function printWarning(level, format, args) {
55
58
  // When changing this logic, you might want to also
@@ -58,6 +61,9 @@ function printWarning(level, format, args) {
58
61
  var isErrorLogger = format === '%s\n\n%s\n' || format === '%o\n\n%s\n\n%s\n';
59
62
 
60
63
  if (ReactSharedInternalsServer.getCurrentStack) {
64
+ // We only add the current stack to the console when createTask is not supported.
65
+ // Since createTask requires DevTools to be open to work, this means that stacks
66
+ // can be lost while DevTools isn't open but we can't detect this.
61
67
  var stack = ReactSharedInternalsServer.getCurrentStack();
62
68
 
63
69
  if (stack !== '') {
@@ -88,9 +94,6 @@ function printWarning(level, format, args) {
88
94
  }
89
95
  }
90
96
 
91
- // -----------------------------------------------------------------------------
92
- var enablePostpone = false;
93
-
94
97
  function scheduleWork(callback) {
95
98
  setTimeout(callback, 0);
96
99
  }
@@ -2029,7 +2032,7 @@ validated) // DEV-only
2029
2032
  result = callComponentInDEV(Component, props, componentDebugInfo);
2030
2033
  }
2031
2034
 
2032
- if (typeof result === 'object' && result !== null) {
2035
+ if (typeof result === 'object' && result !== null && !isClientReference(result)) {
2033
2036
  if (typeof result.then === 'function') {
2034
2037
  // When the return value is in children position we can resolve it immediately,
2035
2038
  // to its value without a wrapper if it's synchronously available.
@@ -947,7 +947,11 @@ function renderFunctionComponent(request, task, key, Component, props) {
947
947
  thenableIndexCounter = 0;
948
948
  thenableState = prevThenableState;
949
949
  Component = Component(props, void 0);
950
- if ("object" === typeof Component && null !== Component) {
950
+ if (
951
+ "object" === typeof Component &&
952
+ null !== Component &&
953
+ Component.$$typeof !== CLIENT_REFERENCE_TAG$1
954
+ ) {
951
955
  if ("function" === typeof Component.then) {
952
956
  props = Component;
953
957
  if ("fulfilled" === props.status) return props.value;
@@ -42,6 +42,9 @@ if (!ReactSharedInternalsServer) {
42
42
  throw new Error('The "react" package in this environment is not configured correctly. ' + 'The "react-server" condition must be enabled in any environment that ' + 'runs React Server Components.');
43
43
  }
44
44
 
45
+ // -----------------------------------------------------------------------------
46
+ var enablePostpone = false;
47
+
45
48
  function error(format) {
46
49
  {
47
50
  {
@@ -52,7 +55,7 @@ function error(format) {
52
55
  printWarning('error', format, args);
53
56
  }
54
57
  }
55
- }
58
+ } // eslint-disable-next-line react-internal/no-production-logging
56
59
 
57
60
  function printWarning(level, format, args) {
58
61
  // When changing this logic, you might want to also
@@ -61,6 +64,9 @@ function printWarning(level, format, args) {
61
64
  var isErrorLogger = format === '%s\n\n%s\n' || format === '%o\n\n%s\n\n%s\n';
62
65
 
63
66
  if (ReactSharedInternalsServer.getCurrentStack) {
67
+ // We only add the current stack to the console when createTask is not supported.
68
+ // Since createTask requires DevTools to be open to work, this means that stacks
69
+ // can be lost while DevTools isn't open but we can't detect this.
64
70
  var stack = ReactSharedInternalsServer.getCurrentStack();
65
71
 
66
72
  if (stack !== '') {
@@ -91,9 +97,6 @@ function printWarning(level, format, args) {
91
97
  }
92
98
  }
93
99
 
94
- // -----------------------------------------------------------------------------
95
- var enablePostpone = false;
96
-
97
100
  function scheduleWork(callback) {
98
101
  setImmediate(callback);
99
102
  }
@@ -2080,7 +2083,7 @@ validated) // DEV-only
2080
2083
  result = callComponentInDEV(Component, props, componentDebugInfo);
2081
2084
  }
2082
2085
 
2083
- if (typeof result === 'object' && result !== null) {
2086
+ if (typeof result === 'object' && result !== null && !isClientReference(result)) {
2084
2087
  if (typeof result.then === 'function') {
2085
2088
  // When the return value is in children position we can resolve it immediately,
2086
2089
  // to its value without a wrapper if it's synchronously available.
@@ -973,7 +973,11 @@ function renderFunctionComponent(request, task, key, Component, props) {
973
973
  thenableIndexCounter = 0;
974
974
  thenableState = prevThenableState;
975
975
  Component = Component(props, void 0);
976
- if ("object" === typeof Component && null !== Component) {
976
+ if (
977
+ "object" === typeof Component &&
978
+ null !== Component &&
979
+ Component.$$typeof !== CLIENT_REFERENCE_TAG$1
980
+ ) {
977
981
  if ("function" === typeof Component.then) {
978
982
  props = Component;
979
983
  if ("fulfilled" === props.status) return props.value;
@@ -42,6 +42,9 @@ if (!ReactSharedInternalsServer) {
42
42
  throw new Error('The "react" package in this environment is not configured correctly. ' + 'The "react-server" condition must be enabled in any environment that ' + 'runs React Server Components.');
43
43
  }
44
44
 
45
+ // -----------------------------------------------------------------------------
46
+ var enablePostpone = false;
47
+
45
48
  function error(format) {
46
49
  {
47
50
  {
@@ -52,7 +55,7 @@ function error(format) {
52
55
  printWarning('error', format, args);
53
56
  }
54
57
  }
55
- }
58
+ } // eslint-disable-next-line react-internal/no-production-logging
56
59
 
57
60
  function printWarning(level, format, args) {
58
61
  // When changing this logic, you might want to also
@@ -61,6 +64,9 @@ function printWarning(level, format, args) {
61
64
  var isErrorLogger = format === '%s\n\n%s\n' || format === '%o\n\n%s\n\n%s\n';
62
65
 
63
66
  if (ReactSharedInternalsServer.getCurrentStack) {
67
+ // We only add the current stack to the console when createTask is not supported.
68
+ // Since createTask requires DevTools to be open to work, this means that stacks
69
+ // can be lost while DevTools isn't open but we can't detect this.
64
70
  var stack = ReactSharedInternalsServer.getCurrentStack();
65
71
 
66
72
  if (stack !== '') {
@@ -91,9 +97,6 @@ function printWarning(level, format, args) {
91
97
  }
92
98
  }
93
99
 
94
- // -----------------------------------------------------------------------------
95
- var enablePostpone = false;
96
-
97
100
  function scheduleWork(callback) {
98
101
  setImmediate(callback);
99
102
  }
@@ -2080,7 +2083,7 @@ validated) // DEV-only
2080
2083
  result = callComponentInDEV(Component, props, componentDebugInfo);
2081
2084
  }
2082
2085
 
2083
- if (typeof result === 'object' && result !== null) {
2086
+ if (typeof result === 'object' && result !== null && !isClientReference(result)) {
2084
2087
  if (typeof result.then === 'function') {
2085
2088
  // When the return value is in children position we can resolve it immediately,
2086
2089
  // to its value without a wrapper if it's synchronously available.
@@ -973,7 +973,11 @@ function renderFunctionComponent(request, task, key, Component, props) {
973
973
  thenableIndexCounter = 0;
974
974
  thenableState = prevThenableState;
975
975
  Component = Component(props, void 0);
976
- if ("object" === typeof Component && null !== Component) {
976
+ if (
977
+ "object" === typeof Component &&
978
+ null !== Component &&
979
+ Component.$$typeof !== CLIENT_REFERENCE_TAG$1
980
+ ) {
977
981
  if ("function" === typeof Component.then) {
978
982
  props = Component;
979
983
  if ("fulfilled" === props.status) return props.value;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "react-server-dom-webpack",
3
3
  "description": "React Server Components bindings for DOM using Webpack. This is intended to be integrated into meta-frameworks. It is not intended to be imported directly.",
4
- "version": "19.0.0-rc-935180c7e0-20240524",
4
+ "version": "19.0.0-rc-38e3b23483-20240529",
5
5
  "keywords": [
6
6
  "react"
7
7
  ],
@@ -77,8 +77,8 @@
77
77
  "node": ">=0.10.0"
78
78
  },
79
79
  "peerDependencies": {
80
- "react": "19.0.0-rc-935180c7e0-20240524",
81
- "react-dom": "19.0.0-rc-935180c7e0-20240524",
80
+ "react": "19.0.0-rc-38e3b23483-20240529",
81
+ "react-dom": "19.0.0-rc-38e3b23483-20240529",
82
82
  "webpack": "^5.59.0"
83
83
  },
84
84
  "dependencies": {