Skip to content

Commit

Permalink
Update React from 14898b6a9 to e373190fa
Browse files Browse the repository at this point in the history
- facebook/react#28596
- facebook/react#28625
- facebook/react#28616
- facebook/react#28491
- facebook/react#28583
- facebook/react#28427
- facebook/react#28613
- facebook/react#28599
- facebook/react#28611
- facebook/react#28610
- facebook/react#28606
- facebook/react#28598
- facebook/react#28549
- facebook/react#28557
- facebook/react#28467
- facebook/react#28591
- facebook/react#28459
- facebook/react#28590
- facebook/react#28564
- facebook/react#28582
- facebook/react#28579
- facebook/react#28578
- facebook/react#28521
- facebook/react#28550
- facebook/react#28576
- facebook/react#28577
- facebook/react#28571
- facebook/react#28572
- facebook/react#28560
- facebook/react#28569
- facebook/react#28573
- facebook/react#28546
- facebook/react#28568
- facebook/react#28562
- facebook/react#28566
- facebook/react#28565
- facebook/react#28559
- facebook/react#28508
- facebook/react#20432
- facebook/react#28555
- facebook/react#24730
- facebook/react#28472
- facebook/react#27991
- facebook/react#28514
- facebook/react#28548
- facebook/react#28526
- facebook/react#28515
- facebook/react#28533
- facebook/react#28532
- facebook/react#28531
- facebook/react#28407
- facebook/react#28522
- facebook/react#28538
- facebook/react#28509
- facebook/react#28534
- facebook/react#28527
- facebook/react#28528
- facebook/react#28519
- facebook/react#28411
- facebook/react#28520
- facebook/react#28518
- facebook/react#28493
- facebook/react#28504
- facebook/react#28499
- facebook/react#28501
- facebook/react#28496
- facebook/react#28471
- facebook/react#28351
- facebook/react#28486
- facebook/react#28490
- facebook/react#28488
- facebook/react#28468
- facebook/react#28321
- facebook/react#28477
- facebook/react#28479
- facebook/react#28480
- facebook/react#28478
- facebook/react#28464
- facebook/react#28475
- facebook/react#28456
- facebook/react#28319
- facebook/react#28345
- facebook/react#28337
- facebook/react#28335
- facebook/react#28466
- facebook/react#28462
- facebook/react#28322
- facebook/react#28444
- facebook/react#28448
- facebook/react#28449
- facebook/react#28446
- facebook/react#28447
- facebook/react#24580
  • Loading branch information
gnoff committed Mar 25, 2024
1 parent 3a50598 commit 1a2ce1f
Show file tree
Hide file tree
Showing 204 changed files with 30,853 additions and 29,427 deletions.
20 changes: 10 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -198,16 +198,16 @@
"random-seed": "0.3.0",
"react": "18.2.0",
"react-17": "npm:react@17.0.2",
"react-builtin": "npm:react@18.3.0-canary-14898b6a9-20240318",
"react-builtin": "npm:react@18.3.0-canary-e373190fa-20240325",
"react-dom": "18.2.0",
"react-dom-17": "npm:react-dom@17.0.2",
"react-dom-builtin": "npm:react-dom@18.3.0-canary-14898b6a9-20240318",
"react-dom-experimental-builtin": "npm:react-dom@0.0.0-experimental-14898b6a9-20240318",
"react-experimental-builtin": "npm:react@0.0.0-experimental-14898b6a9-20240318",
"react-server-dom-turbopack": "18.3.0-canary-14898b6a9-20240318",
"react-server-dom-turbopack-experimental": "npm:react-server-dom-turbopack@0.0.0-experimental-14898b6a9-20240318",
"react-server-dom-webpack": "18.3.0-canary-14898b6a9-20240318",
"react-server-dom-webpack-experimental": "npm:react-server-dom-webpack@0.0.0-experimental-14898b6a9-20240318",
"react-dom-builtin": "npm:react-dom@18.3.0-canary-e373190fa-20240325",
"react-dom-experimental-builtin": "npm:react-dom@0.0.0-experimental-e373190fa-20240325",
"react-experimental-builtin": "npm:react@0.0.0-experimental-e373190fa-20240325",
"react-server-dom-turbopack": "18.3.0-canary-e373190fa-20240325",
"react-server-dom-turbopack-experimental": "npm:react-server-dom-turbopack@0.0.0-experimental-e373190fa-20240325",
"react-server-dom-webpack": "18.3.0-canary-e373190fa-20240325",
"react-server-dom-webpack-experimental": "npm:react-server-dom-webpack@0.0.0-experimental-e373190fa-20240325",
"react-ssr-prepass": "1.0.8",
"react-virtualized": "9.22.3",
"relay-compiler": "13.0.2",
Expand All @@ -217,8 +217,8 @@
"resolve-from": "5.0.0",
"sass": "1.54.0",
"satori": "0.10.9",
"scheduler-builtin": "npm:scheduler@0.24.0-canary-14898b6a9-20240318",
"scheduler-experimental-builtin": "npm:scheduler@0.0.0-experimental-14898b6a9-20240318",
"scheduler-builtin": "npm:scheduler@0.24.0-canary-e373190fa-20240325",
"scheduler-experimental-builtin": "npm:scheduler@0.0.0-experimental-e373190fa-20240325",
"seedrandom": "3.0.5",
"selenium-webdriver": "4.0.0-beta.4",
"semver": "7.3.7",
Expand Down

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,24 @@ function printWarning(level, format, args) {
}
}

var ReactVersion = '18.3.0-experimental-14898b6a9-20240318';

var ReactVersion = '18.3.0-experimental-e373190fa-20240325';

function noop() {}

var DefaultDispatcher = {
prefetchDNS: noop,
preconnect: noop,
preload: noop,
preloadModule: noop,
preinitScript: noop,
preinitStyle: noop,
preinitModuleScript: noop
};
var Internals = {
usingClientEntryPoint: false,
Events: null,
Dispatcher: {
current: null
ReactDOMCurrentDispatcher: {
current: DefaultDispatcher
}
};

Expand All @@ -84,7 +95,7 @@ function getCrossOriginStringAs(as, input) {
return undefined;
}

var Dispatcher = Internals.Dispatcher;
var ReactDOMCurrentDispatcher = Internals.ReactDOMCurrentDispatcher;
function prefetchDNS(href) {
{
if (typeof href !== 'string' || !href) {
Expand All @@ -100,10 +111,8 @@ function prefetchDNS(href) {
}
}

var dispatcher = Dispatcher.current;

if (dispatcher && typeof href === 'string') {
dispatcher.prefetchDNS(href);
if (typeof href === 'string') {
ReactDOMCurrentDispatcher.current.prefetchDNS(href);
} // We don't error because preconnect needs to be resilient to being called in a variety of scopes
// and the runtime may not be capable of responding. The function is optimistic and not critical
// so we favor silent bailout over warning or erroring.
Expand All @@ -120,11 +129,9 @@ function preconnect(href, options) {
}
}

var dispatcher = Dispatcher.current;

if (dispatcher && typeof href === 'string') {
if (typeof href === 'string') {
var crossOrigin = options ? getCrossOriginString(options.crossOrigin) : null;
dispatcher.preconnect(href, crossOrigin);
ReactDOMCurrentDispatcher.current.preconnect(href, crossOrigin);
} // We don't error because preconnect needs to be resilient to being called in a variety of scopes
// and the runtime may not be capable of responding. The function is optimistic and not critical
// so we favor silent bailout over warning or erroring.
Expand All @@ -149,13 +156,11 @@ function preload(href, options) {
}
}

var dispatcher = Dispatcher.current;

if (dispatcher && typeof href === 'string' && // We check existence because we cannot enforce this function is actually called with the stated type
if (typeof href === 'string' && // We check existence because we cannot enforce this function is actually called with the stated type
typeof options === 'object' && options !== null && typeof options.as === 'string') {
var as = options.as;
var crossOrigin = getCrossOriginStringAs(as, options.crossOrigin);
dispatcher.preload(href, as, {
ReactDOMCurrentDispatcher.current.preload(href, as, {
crossOrigin: crossOrigin,
integrity: typeof options.integrity === 'string' ? options.integrity : undefined,
nonce: typeof options.nonce === 'string' ? options.nonce : undefined,
Expand Down Expand Up @@ -189,18 +194,16 @@ function preloadModule(href, options) {
}
}

var dispatcher = Dispatcher.current;

if (dispatcher && typeof href === 'string') {
if (typeof href === 'string') {
if (options) {
var crossOrigin = getCrossOriginStringAs(options.as, options.crossOrigin);
dispatcher.preloadModule(href, {
ReactDOMCurrentDispatcher.current.preloadModule(href, {
as: typeof options.as === 'string' && options.as !== 'script' ? options.as : undefined,
crossOrigin: crossOrigin,
integrity: typeof options.integrity === 'string' ? options.integrity : undefined
});
} else {
dispatcher.preloadModule(href);
ReactDOMCurrentDispatcher.current.preloadModule(href);
}
} // We don't error because preload needs to be resilient to being called in a variety of scopes
// and the runtime may not be capable of responding. The function is optimistic and not critical
Expand All @@ -218,22 +221,20 @@ function preinit(href, options) {
}
}

var dispatcher = Dispatcher.current;

if (dispatcher && typeof href === 'string' && options && typeof options.as === 'string') {
if (typeof href === 'string' && options && typeof options.as === 'string') {
var as = options.as;
var crossOrigin = getCrossOriginStringAs(as, options.crossOrigin);
var integrity = typeof options.integrity === 'string' ? options.integrity : undefined;
var fetchPriority = typeof options.fetchPriority === 'string' ? options.fetchPriority : undefined;

if (as === 'style') {
dispatcher.preinitStyle(href, typeof options.precedence === 'string' ? options.precedence : undefined, {
ReactDOMCurrentDispatcher.current.preinitStyle(href, typeof options.precedence === 'string' ? options.precedence : undefined, {
crossOrigin: crossOrigin,
integrity: integrity,
fetchPriority: fetchPriority
});
} else if (as === 'script') {
dispatcher.preinitScript(href, {
ReactDOMCurrentDispatcher.current.preinitScript(href, {
crossOrigin: crossOrigin,
integrity: integrity,
fetchPriority: fetchPriority,
Expand Down Expand Up @@ -281,20 +282,18 @@ function preinitModule(href, options) {
}
}

var dispatcher = Dispatcher.current;

if (dispatcher && typeof href === 'string') {
if (typeof href === 'string') {
if (typeof options === 'object' && options !== null) {
if (options.as == null || options.as === 'script') {
var crossOrigin = getCrossOriginStringAs(options.as, options.crossOrigin);
dispatcher.preinitModuleScript(href, {
ReactDOMCurrentDispatcher.current.preinitModuleScript(href, {
crossOrigin: crossOrigin,
integrity: typeof options.integrity === 'string' ? options.integrity : undefined,
nonce: typeof options.nonce === 'string' ? options.nonce : undefined
});
}
} else if (options == null) {
dispatcher.preinitModuleScript(href);
ReactDOMCurrentDispatcher.current.preinitModuleScript(href);
}
} // We don't error because preinit needs to be resilient to being called in a variety of scopes
// and the runtime may not be capable of responding. The function is optimistic and not critical
Expand All @@ -319,7 +318,7 @@ function resolveDispatcher() {

{
if (dispatcher === null) {
error('Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for' + ' one of the following reasons:\n' + '1. You might have mismatching versions of React and the renderer (such as React DOM)\n' + '2. You might be breaking the Rules of Hooks\n' + '3. You might have more than one copy of React in the same app\n' + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.');
error('Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for' + ' one of the following reasons:\n' + '1. You might have mismatching versions of React and the renderer (such as React DOM)\n' + '2. You might be breaking the Rules of Hooks\n' + '3. You might have more than one copy of React in the same app\n' + 'See https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.');
}
} // Will result in a null access error if accessed outside render phase. We
// intentionally don't throw our own error because this is in a hot path.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,24 @@

var React = require("next/dist/compiled/react-experimental");

var ReactVersion = '18.3.0-experimental-14898b6a9-20240318';

var ReactVersion = '18.3.0-experimental-e373190fa-20240325';

function noop() {}

const DefaultDispatcher = {
prefetchDNS: noop,
preconnect: noop,
preload: noop,
preloadModule: noop,
preinitScript: noop,
preinitStyle: noop,
preinitModuleScript: noop
};
const Internals = {
usingClientEntryPoint: false,
Events: null,
Dispatcher: {
current: null
ReactDOMCurrentDispatcher: {
current: DefaultDispatcher
}
};

Expand Down Expand Up @@ -58,39 +69,33 @@ function getCrossOriginStringAs(as, input) {
return undefined;
}

const Dispatcher = Internals.Dispatcher;
const ReactDOMCurrentDispatcher = Internals.ReactDOMCurrentDispatcher;
function prefetchDNS(href) {

const dispatcher = Dispatcher.current;

if (dispatcher && typeof href === 'string') {
dispatcher.prefetchDNS(href);
if (typeof href === 'string') {
ReactDOMCurrentDispatcher.current.prefetchDNS(href);
} // We don't error because preconnect needs to be resilient to being called in a variety of scopes
// and the runtime may not be capable of responding. The function is optimistic and not critical
// so we favor silent bailout over warning or erroring.

}
function preconnect(href, options) {

const dispatcher = Dispatcher.current;

if (dispatcher && typeof href === 'string') {
if (typeof href === 'string') {
const crossOrigin = options ? getCrossOriginString(options.crossOrigin) : null;
dispatcher.preconnect(href, crossOrigin);
ReactDOMCurrentDispatcher.current.preconnect(href, crossOrigin);
} // We don't error because preconnect needs to be resilient to being called in a variety of scopes
// and the runtime may not be capable of responding. The function is optimistic and not critical
// so we favor silent bailout over warning or erroring.

}
function preload(href, options) {

const dispatcher = Dispatcher.current;

if (dispatcher && typeof href === 'string' && // We check existence because we cannot enforce this function is actually called with the stated type
if (typeof href === 'string' && // We check existence because we cannot enforce this function is actually called with the stated type
typeof options === 'object' && options !== null && typeof options.as === 'string') {
const as = options.as;
const crossOrigin = getCrossOriginStringAs(as, options.crossOrigin);
dispatcher.preload(href, as, {
ReactDOMCurrentDispatcher.current.preload(href, as, {
crossOrigin,
integrity: typeof options.integrity === 'string' ? options.integrity : undefined,
nonce: typeof options.nonce === 'string' ? options.nonce : undefined,
Expand All @@ -107,18 +112,16 @@ function preload(href, options) {
}
function preloadModule(href, options) {

const dispatcher = Dispatcher.current;

if (dispatcher && typeof href === 'string') {
if (typeof href === 'string') {
if (options) {
const crossOrigin = getCrossOriginStringAs(options.as, options.crossOrigin);
dispatcher.preloadModule(href, {
ReactDOMCurrentDispatcher.current.preloadModule(href, {
as: typeof options.as === 'string' && options.as !== 'script' ? options.as : undefined,
crossOrigin,
integrity: typeof options.integrity === 'string' ? options.integrity : undefined
});
} else {
dispatcher.preloadModule(href);
ReactDOMCurrentDispatcher.current.preloadModule(href);
}
} // We don't error because preload needs to be resilient to being called in a variety of scopes
// and the runtime may not be capable of responding. The function is optimistic and not critical
Expand All @@ -127,22 +130,20 @@ function preloadModule(href, options) {
}
function preinit(href, options) {

const dispatcher = Dispatcher.current;

if (dispatcher && typeof href === 'string' && options && typeof options.as === 'string') {
if (typeof href === 'string' && options && typeof options.as === 'string') {
const as = options.as;
const crossOrigin = getCrossOriginStringAs(as, options.crossOrigin);
const integrity = typeof options.integrity === 'string' ? options.integrity : undefined;
const fetchPriority = typeof options.fetchPriority === 'string' ? options.fetchPriority : undefined;

if (as === 'style') {
dispatcher.preinitStyle(href, typeof options.precedence === 'string' ? options.precedence : undefined, {
ReactDOMCurrentDispatcher.current.preinitStyle(href, typeof options.precedence === 'string' ? options.precedence : undefined, {
crossOrigin,
integrity,
fetchPriority
});
} else if (as === 'script') {
dispatcher.preinitScript(href, {
ReactDOMCurrentDispatcher.current.preinitScript(href, {
crossOrigin,
integrity,
fetchPriority,
Expand All @@ -156,20 +157,18 @@ function preinit(href, options) {
}
function preinitModule(href, options) {

const dispatcher = Dispatcher.current;

if (dispatcher && typeof href === 'string') {
if (typeof href === 'string') {
if (typeof options === 'object' && options !== null) {
if (options.as == null || options.as === 'script') {
const crossOrigin = getCrossOriginStringAs(options.as, options.crossOrigin);
dispatcher.preinitModuleScript(href, {
ReactDOMCurrentDispatcher.current.preinitModuleScript(href, {
crossOrigin,
integrity: typeof options.integrity === 'string' ? options.integrity : undefined,
nonce: typeof options.nonce === 'string' ? options.nonce : undefined
});
}
} else if (options == null) {
dispatcher.preinitModuleScript(href);
ReactDOMCurrentDispatcher.current.preinitModuleScript(href);
}
} // We don't error because preinit needs to be resilient to being called in a variety of scopes
// and the runtime may not be capable of responding. The function is optimistic and not critical
Expand Down

0 comments on commit 1a2ce1f

Please sign in to comment.