From 5d8783a98383e25c399cf2745825b65762fb1185 Mon Sep 17 00:00:00 2001 From: CY Lim <5622951+cylim@users.noreply.github.com> Date: Mon, 17 Aug 2020 20:25:50 +0800 Subject: [PATCH] refactor fb.me redirect link to reactjs.org/link (#19598) * refactor fb.me url to reactjs.org/link * Update ESLintRuleExhaustiveDeps-test.js * Update ReactDOMServerIntegrationUntrustedURL-test.internal.js * Update createReactClassIntegration-test.js * Update ReactDOMServerIntegrationUntrustedURL-test.internal.js Co-authored-by: Dan Abramov --- .../ESLintRuleExhaustiveDeps-test.js | 4 +-- .../src/ExhaustiveDeps.js | 2 +- .../__tests__/ReactHooksInspection-test.js | 2 +- .../ReactHooksInspectionIntegration-test.js | 2 +- .../devtools/views/Profiler/NoInteractions.js | 2 +- .../src/devtools/views/Profiler/Profiler.js | 4 +-- packages/react-devtools-shared/src/hook.js | 2 +- .../__tests__/ReactComponentLifeCycle-test.js | 24 ++++++------- .../src/__tests__/ReactDOMAttribute-test.js | 4 +-- .../src/__tests__/ReactDOMComponent-test.js | 8 ++--- .../__tests__/ReactDOMComponentTree-test.js | 2 +- .../src/__tests__/ReactDOMInput-test.js | 36 +++++++++---------- .../__tests__/ReactDOMInvalidARIAHook-test.js | 4 +-- .../src/__tests__/ReactDOMSelect-test.js | 2 +- .../ReactDOMServerIntegrationHooks-test.js | 4 +-- ...erIntegrationUntrustedURL-test.internal.js | 4 +-- .../ReactDOMServerLifecycles-test.js | 2 +- .../src/__tests__/ReactDOMTextarea-test.js | 2 +- .../ReactDeprecationWarnings-test.internal.js | 6 ++-- .../__tests__/ReactFunctionComponent-test.js | 2 +- .../src/__tests__/ReactTestUtils-test.js | 2 +- .../src/__tests__/findDOMNode-test.js | 4 +-- .../multiple-copies-of-react-test.js | 2 +- packages/react-dom/src/__tests__/refs-test.js | 2 +- packages/react-dom/src/client/ReactDOM.js | 6 ++-- .../react-dom/src/client/ReactDOMInput.js | 8 ++--- .../react-dom/src/client/ReactDOMSelect.js | 2 +- .../react-dom/src/client/ReactDOMTextarea.js | 2 +- .../src/server/ReactPartialRenderer.js | 10 +++--- .../src/server/ReactPartialRendererHooks.js | 6 ++-- .../src/shared/ReactDOMInvalidARIAHook.js | 4 +-- .../src/shared/ReactDOMUnknownPropertyHook.js | 4 +-- .../react-dom/src/shared/assertValidProps.js | 2 +- .../src/test-utils/ReactTestUtils.js | 2 +- .../__tests__/ReactFabric-test.internal.js | 8 ++--- .../ReactNativeMount-test.internal.js | 8 ++--- .../src/legacy-events/SyntheticEvent.js | 2 +- .../src/ReactChildFiber.new.js | 10 +++--- .../src/ReactChildFiber.old.js | 10 +++--- .../src/ReactFiberClassComponent.new.js | 2 +- .../src/ReactFiberClassComponent.old.js | 2 +- .../src/ReactFiberCommitWork.new.js | 2 +- .../src/ReactFiberCommitWork.old.js | 2 +- .../src/ReactFiberDevToolsHook.new.js | 2 +- .../src/ReactFiberDevToolsHook.old.js | 2 +- .../src/ReactFiberErrorLogger.js | 2 +- .../src/ReactFiberHooks.new.js | 6 ++-- .../src/ReactFiberHooks.old.js | 6 ++-- .../src/ReactFiberReconciler.new.js | 4 +-- .../src/ReactFiberReconciler.old.js | 4 +-- .../src/ReactFiberWorkLoop.new.js | 10 +++--- .../src/ReactFiberWorkLoop.old.js | 10 +++--- .../src/ReactStrictModeWarnings.new.js | 18 +++++----- .../src/ReactStrictModeWarnings.old.js | 18 +++++----- .../src/SchedulerWithReactIntegration.new.js | 2 +- .../src/SchedulerWithReactIntegration.old.js | 2 +- .../src/__tests__/ReactBlocks-test.js | 2 +- .../src/__tests__/ReactHooks-test.internal.js | 18 +++++----- .../ReactHooksWithNoopRenderer-test.js | 10 +++--- .../src/__tests__/ReactNewContext-test.js | 4 +-- .../__tests__/ReactTracing-test.internal.js | 2 +- packages/react/src/ReactElement.js | 6 ++-- packages/react/src/ReactElementValidator.js | 2 +- packages/react/src/ReactHooks.js | 4 +-- .../react/src/__tests__/ReactChildren-test.js | 4 +-- .../react/src/__tests__/ReactElement-test.js | 6 ++-- .../src/__tests__/ReactElementJSX-test.js | 8 ++--- .../ReactElementValidator-test.internal.js | 6 ++-- .../src/__tests__/ReactStrictMode-test.js | 30 ++++++++-------- .../createReactClassIntegration-test.js | 4 +-- packages/react/src/jsx/ReactJSXElement.js | 6 ++-- .../react/src/jsx/ReactJSXElementValidator.js | 2 +- .../src/forks/SchedulerHostConfig.default.js | 4 +-- packages/shared/invokeGuardedCallbackImpl.js | 2 +- scripts/error-codes/codes.json | 26 +++++++------- 75 files changed, 226 insertions(+), 226 deletions(-) diff --git a/packages/eslint-plugin-react-hooks/__tests__/ESLintRuleExhaustiveDeps-test.js b/packages/eslint-plugin-react-hooks/__tests__/ESLintRuleExhaustiveDeps-test.js index 26cda5e290875..4de51e9c4043a 100644 --- a/packages/eslint-plugin-react-hooks/__tests__/ESLintRuleExhaustiveDeps-test.js +++ b/packages/eslint-plugin-react-hooks/__tests__/ESLintRuleExhaustiveDeps-test.js @@ -6633,7 +6633,7 @@ const tests = { ' }\n' + ' fetchData();\n' + `}, [someId]); // Or [] if effect doesn't need props or state\n\n` + - 'Learn more about data fetching with Hooks: https://fb.me/react-hooks-data-fetching', + 'Learn more about data fetching with Hooks: https://reactjs.org/link/hooks-data-fetching', suggestions: undefined, }, ], @@ -6657,7 +6657,7 @@ const tests = { ' }\n' + ' fetchData();\n' + `}, [someId]); // Or [] if effect doesn't need props or state\n\n` + - 'Learn more about data fetching with Hooks: https://fb.me/react-hooks-data-fetching', + 'Learn more about data fetching with Hooks: https://reactjs.org/link/hooks-data-fetching', suggestions: undefined, }, ], diff --git a/packages/eslint-plugin-react-hooks/src/ExhaustiveDeps.js b/packages/eslint-plugin-react-hooks/src/ExhaustiveDeps.js index ab552c305a4db..ed48afa7869c1 100644 --- a/packages/eslint-plugin-react-hooks/src/ExhaustiveDeps.js +++ b/packages/eslint-plugin-react-hooks/src/ExhaustiveDeps.js @@ -258,7 +258,7 @@ export default { ' }\n' + ' fetchData();\n' + `}, [someId]); // Or [] if effect doesn't need props or state\n\n` + - 'Learn more about data fetching with Hooks: https://fb.me/react-hooks-data-fetching', + 'Learn more about data fetching with Hooks: https://reactjs.org/link/hooks-data-fetching', }); } diff --git a/packages/react-debug-tools/src/__tests__/ReactHooksInspection-test.js b/packages/react-debug-tools/src/__tests__/ReactHooksInspection-test.js index 49786ddfd8ac2..602fb613d417f 100644 --- a/packages/react-debug-tools/src/__tests__/ReactHooksInspection-test.js +++ b/packages/react-debug-tools/src/__tests__/ReactHooksInspection-test.js @@ -284,7 +284,7 @@ describe('ReactHooksInspection', () => { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); expect(getterCalls).toBe(1); diff --git a/packages/react-debug-tools/src/__tests__/ReactHooksInspectionIntegration-test.js b/packages/react-debug-tools/src/__tests__/ReactHooksInspectionIntegration-test.js index 7bffd1d809658..01461dfc1648e 100644 --- a/packages/react-debug-tools/src/__tests__/ReactHooksInspectionIntegration-test.js +++ b/packages/react-debug-tools/src/__tests__/ReactHooksInspectionIntegration-test.js @@ -787,7 +787,7 @@ describe('ReactHooksInspectionIntegration', () => { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); expect(getterCalls).toBe(1); diff --git a/packages/react-devtools-shared/src/devtools/views/Profiler/NoInteractions.js b/packages/react-devtools-shared/src/devtools/views/Profiler/NoInteractions.js index 932c906cc7c05..c2f1f65480d1f 100644 --- a/packages/react-devtools-shared/src/devtools/views/Profiler/NoInteractions.js +++ b/packages/react-devtools-shared/src/devtools/views/Profiler/NoInteractions.js @@ -24,7 +24,7 @@ export default function NoInteractions({

Learn more about the interaction tracing API here. diff --git a/packages/react-devtools-shared/src/devtools/views/Profiler/Profiler.js b/packages/react-devtools-shared/src/devtools/views/Profiler/Profiler.js index 2756ba0c9f832..2b4e117d66d96 100644 --- a/packages/react-devtools-shared/src/devtools/views/Profiler/Profiler.js +++ b/packages/react-devtools-shared/src/devtools/views/Profiler/Profiler.js @@ -176,10 +176,10 @@ const ProfilingNotSupported = () => ( Learn more at{' '} - fb.me/react-profiling + reactjs.org/link/profiling .

diff --git a/packages/react-devtools-shared/src/hook.js b/packages/react-devtools-shared/src/hook.js index 4b018e61421b1..f9f65df7fb9c8 100644 --- a/packages/react-devtools-shared/src/hook.js +++ b/packages/react-devtools-shared/src/hook.js @@ -145,7 +145,7 @@ export function installHook(target: any): DevToolsHook | null { 'React is running in production mode, but dead code ' + 'elimination has not been applied. Read how to correctly ' + 'configure React for production: ' + - 'https://fb.me/react-perf-use-the-production-build', + 'https://reactjs.org/link/perf-use-production-build', ); }); } diff --git a/packages/react-dom/src/__tests__/ReactComponentLifeCycle-test.js b/packages/react-dom/src/__tests__/ReactComponentLifeCycle-test.js index 939b7b77203ec..1a02d22d5dbfe 100644 --- a/packages/react-dom/src/__tests__/ReactComponentLifeCycle-test.js +++ b/packages/react-dom/src/__tests__/ReactComponentLifeCycle-test.js @@ -801,7 +801,7 @@ describe('ReactComponentLifeCycle', () => { ' UNSAFE_componentWillReceiveProps\n' + ' componentWillUpdate\n\n' + 'The above lifecycles should be removed. Learn more about this warning here:\n' + - 'https://fb.me/react-unsafe-component-lifecycles', + 'https://reactjs.org/link/unsafe-component-lifecycles', ); }).toWarnDev( [ @@ -827,7 +827,7 @@ describe('ReactComponentLifeCycle', () => { 'WillMount uses getDerivedStateFromProps() but also contains the following legacy lifecycles:\n' + ' UNSAFE_componentWillMount\n\n' + 'The above lifecycles should be removed. Learn more about this warning here:\n' + - 'https://fb.me/react-unsafe-component-lifecycles', + 'https://reactjs.org/link/unsafe-component-lifecycles', ); class WillMountAndUpdate extends React.Component { @@ -851,7 +851,7 @@ describe('ReactComponentLifeCycle', () => { ' componentWillMount\n' + ' UNSAFE_componentWillUpdate\n\n' + 'The above lifecycles should be removed. Learn more about this warning here:\n' + - 'https://fb.me/react-unsafe-component-lifecycles', + 'https://reactjs.org/link/unsafe-component-lifecycles', ); }).toWarnDev(['componentWillMount has been renamed'], { withoutStack: true, @@ -874,7 +874,7 @@ describe('ReactComponentLifeCycle', () => { 'WillReceiveProps uses getDerivedStateFromProps() but also contains the following legacy lifecycles:\n' + ' componentWillReceiveProps\n\n' + 'The above lifecycles should be removed. Learn more about this warning here:\n' + - 'https://fb.me/react-unsafe-component-lifecycles', + 'https://reactjs.org/link/unsafe-component-lifecycles', ); }).toWarnDev(['componentWillReceiveProps has been renamed'], { withoutStack: true, @@ -906,7 +906,7 @@ describe('ReactComponentLifeCycle', () => { ' UNSAFE_componentWillReceiveProps\n' + ' componentWillUpdate\n\n' + 'The above lifecycles should be removed. Learn more about this warning here:\n' + - 'https://fb.me/react-unsafe-component-lifecycles', + 'https://reactjs.org/link/unsafe-component-lifecycles', ); }).toWarnDev( [ @@ -931,7 +931,7 @@ describe('ReactComponentLifeCycle', () => { 'WillMount uses getSnapshotBeforeUpdate() but also contains the following legacy lifecycles:\n' + ' UNSAFE_componentWillMount\n\n' + 'The above lifecycles should be removed. Learn more about this warning here:\n' + - 'https://fb.me/react-unsafe-component-lifecycles', + 'https://reactjs.org/link/unsafe-component-lifecycles', ); class WillMountAndUpdate extends React.Component { @@ -954,7 +954,7 @@ describe('ReactComponentLifeCycle', () => { ' componentWillMount\n' + ' UNSAFE_componentWillUpdate\n\n' + 'The above lifecycles should be removed. Learn more about this warning here:\n' + - 'https://fb.me/react-unsafe-component-lifecycles', + 'https://reactjs.org/link/unsafe-component-lifecycles', ); }).toWarnDev(['componentWillMount has been renamed'], { withoutStack: true, @@ -976,7 +976,7 @@ describe('ReactComponentLifeCycle', () => { 'WillReceiveProps uses getSnapshotBeforeUpdate() but also contains the following legacy lifecycles:\n' + ' componentWillReceiveProps\n\n' + 'The above lifecycles should be removed. Learn more about this warning here:\n' + - 'https://fb.me/react-unsafe-component-lifecycles', + 'https://reactjs.org/link/unsafe-component-lifecycles', ); }).toWarnDev(['componentWillReceiveProps has been renamed'], { withoutStack: true, @@ -1383,20 +1383,20 @@ describe('ReactComponentLifeCycle', () => { expect(() => ReactDOM.render(, container)).toWarnDev( [ /* eslint-disable max-len */ - `Warning: componentWillMount has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details. + `Warning: componentWillMount has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details. * Move code with side effects to componentDidMount, and set initial state in the constructor. * Rename componentWillMount to UNSAFE_componentWillMount to suppress this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run \`npx react-codemod rename-unsafe-lifecycles\` in your project source folder. Please update the following components: MyComponent`, - `Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details. + `Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details. * Move data fetching code or side effects to componentDidUpdate. -* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state +* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://reactjs.org/link/derived-state * Rename componentWillReceiveProps to UNSAFE_componentWillReceiveProps to suppress this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run \`npx react-codemod rename-unsafe-lifecycles\` in your project source folder. Please update the following components: MyComponent`, - `Warning: componentWillUpdate has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details. + `Warning: componentWillUpdate has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details. * Move data fetching code or side effects to componentDidUpdate. * Rename componentWillUpdate to UNSAFE_componentWillUpdate to suppress this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run \`npx react-codemod rename-unsafe-lifecycles\` in your project source folder. diff --git a/packages/react-dom/src/__tests__/ReactDOMAttribute-test.js b/packages/react-dom/src/__tests__/ReactDOMAttribute-test.js index efd01b41af73a..aa91857b48009 100644 --- a/packages/react-dom/src/__tests__/ReactDOMAttribute-test.js +++ b/packages/react-dom/src/__tests__/ReactDOMAttribute-test.js @@ -93,7 +93,7 @@ describe('ReactDOM unknown attribute', () => { expect(() => testUnknownAttributeRemoval(Symbol('foo'))).toErrorDev( 'Warning: Invalid value for prop `unknown` on
tag. Either remove it ' + 'from the element, or pass a string or number value to keep it ' + - 'in the DOM. For details, see https://fb.me/react-attribute-behavior\n' + + 'in the DOM. For details, see https://reactjs.org/link/attribute-behavior \n' + ' in div (at **)', ); }); @@ -105,7 +105,7 @@ describe('ReactDOM unknown attribute', () => { 'Warning: Invalid value for prop `unknown` on
tag. Either remove ' + 'it from the element, or pass a string or number value to ' + 'keep it in the DOM. For details, see ' + - 'https://fb.me/react-attribute-behavior\n' + + 'https://reactjs.org/link/attribute-behavior \n' + ' in div (at **)', ); }); diff --git a/packages/react-dom/src/__tests__/ReactDOMComponent-test.js b/packages/react-dom/src/__tests__/ReactDOMComponent-test.js index 3c8ce165ebb90..d4e23c9267337 100644 --- a/packages/react-dom/src/__tests__/ReactDOMComponent-test.js +++ b/packages/react-dom/src/__tests__/ReactDOMComponent-test.js @@ -150,7 +150,7 @@ describe('ReactDOMComponent', () => { ).toErrorDev( 'Warning: Invalid value for prop `foo` on
tag. Either remove it ' + 'from the element, or pass a string or number value to keep ' + - 'it in the DOM. For details, see https://fb.me/react-attribute-behavior' + + 'it in the DOM. For details, see https://reactjs.org/link/attribute-behavior ' + '\n in div (at **)', ); }); @@ -162,7 +162,7 @@ describe('ReactDOMComponent', () => { ).toErrorDev( 'Warning: Invalid values for props `foo`, `baz` on
tag. Either remove ' + 'them from the element, or pass a string or number value to keep ' + - 'them in the DOM. For details, see https://fb.me/react-attribute-behavior' + + 'them in the DOM. For details, see https://reactjs.org/link/attribute-behavior ' + '\n in div (at **)', ); }); @@ -1384,7 +1384,7 @@ describe('ReactDOMComponent', () => { mountComponent({dangerouslySetInnerHTML: 'Hi Jim!'}); }).toThrowError( '`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. ' + - 'Please visit https://fb.me/react-invariant-dangerously-set-inner-html for more information.', + 'Please visit https://reactjs.org/link/dangerously-set-inner-html for more information.', ); }); @@ -1393,7 +1393,7 @@ describe('ReactDOMComponent', () => { mountComponent({dangerouslySetInnerHTML: {foo: 'bar'}}); }).toThrowError( '`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. ' + - 'Please visit https://fb.me/react-invariant-dangerously-set-inner-html for more information.', + 'Please visit https://reactjs.org/link/dangerously-set-inner-html for more information.', ); }); diff --git a/packages/react-dom/src/__tests__/ReactDOMComponentTree-test.js b/packages/react-dom/src/__tests__/ReactDOMComponentTree-test.js index 218c2a81c066c..647c6d5279928 100644 --- a/packages/react-dom/src/__tests__/ReactDOMComponentTree-test.js +++ b/packages/react-dom/src/__tests__/ReactDOMComponentTree-test.js @@ -183,7 +183,7 @@ describe('ReactDOMComponentTree', () => { 'a defined value, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + 'element for the lifetime of the component. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', ); }); diff --git a/packages/react-dom/src/__tests__/ReactDOMInput-test.js b/packages/react-dom/src/__tests__/ReactDOMInput-test.js index f78e11830e4df..018dd14697f08 100644 --- a/packages/react-dom/src/__tests__/ReactDOMInput-test.js +++ b/packages/react-dom/src/__tests__/ReactDOMInput-test.js @@ -1228,7 +1228,7 @@ describe('ReactDOMInput', () => { '(specify either the checked prop, or the defaultChecked prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', ); ReactDOM.unmountComponentAtNode(container); @@ -1255,7 +1255,7 @@ describe('ReactDOMInput', () => { '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', ); ReactDOM.unmountComponentAtNode(container); @@ -1275,7 +1275,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from a defined to ' + 'undefined, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1294,7 +1294,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from a defined to ' + 'undefined, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ]); }); @@ -1314,7 +1314,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from a defined to ' + 'undefined, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1329,7 +1329,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from undefined to ' + 'a defined value, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1347,7 +1347,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from undefined to ' + 'a defined value, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1364,7 +1364,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from a defined to ' + 'undefined, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1381,7 +1381,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from a defined to ' + 'undefined, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1401,7 +1401,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from a defined to ' + 'undefined, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1416,7 +1416,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from undefined to ' + 'a defined value, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1431,7 +1431,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from undefined to ' + 'a defined value, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1444,7 +1444,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from a defined to ' + 'undefined, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1459,7 +1459,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from a defined to ' + 'undefined, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1474,7 +1474,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from a defined to ' + 'undefined, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1489,7 +1489,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from undefined to ' + 'a defined value, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1504,7 +1504,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from undefined to ' + 'a defined value, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); @@ -1557,7 +1557,7 @@ describe('ReactDOMInput', () => { 'This is likely caused by the value changing from a defined to ' + 'undefined, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components\n' + + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components\n' + ' in input (at **)', ); }); diff --git a/packages/react-dom/src/__tests__/ReactDOMInvalidARIAHook-test.js b/packages/react-dom/src/__tests__/ReactDOMInvalidARIAHook-test.js index 7263aac40529e..f3d48aca792fc 100644 --- a/packages/react-dom/src/__tests__/ReactDOMInvalidARIAHook-test.js +++ b/packages/react-dom/src/__tests__/ReactDOMInvalidARIAHook-test.js @@ -31,7 +31,7 @@ describe('ReactDOMInvalidARIAHook', () => { it('should warn for one invalid aria-* prop', () => { expect(() => mountComponent({'aria-badprop': 'maybe'})).toErrorDev( 'Warning: Invalid aria prop `aria-badprop` on
tag. ' + - 'For details, see https://fb.me/invalid-aria-prop', + 'For details, see https://reactjs.org/link/invalid-aria-props', ); }); it('should warn for many invalid aria-* props', () => { @@ -42,7 +42,7 @@ describe('ReactDOMInvalidARIAHook', () => { }), ).toErrorDev( 'Warning: Invalid aria props `aria-badprop`, `aria-malprop` on
' + - 'tag. For details, see https://fb.me/invalid-aria-prop', + 'tag. For details, see https://reactjs.org/link/invalid-aria-props', ); }); it('should warn for an improperly cased aria-* prop', () => { diff --git a/packages/react-dom/src/__tests__/ReactDOMSelect-test.js b/packages/react-dom/src/__tests__/ReactDOMSelect-test.js index 61315f0a95fd5..b9d76492c73b7 100644 --- a/packages/react-dom/src/__tests__/ReactDOMSelect-test.js +++ b/packages/react-dom/src/__tests__/ReactDOMSelect-test.js @@ -693,7 +693,7 @@ describe('ReactDOMSelect', () => { '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled select ' + 'element and remove one of these props. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', ); ReactTestUtils.renderIntoDocument( diff --git a/packages/react-dom/src/__tests__/ReactDOMServerIntegrationHooks-test.js b/packages/react-dom/src/__tests__/ReactDOMServerIntegrationHooks-test.js index 813c0fe1e7ad1..0497a696716cb 100644 --- a/packages/react-dom/src/__tests__/ReactDOMServerIntegrationHooks-test.js +++ b/packages/react-dom/src/__tests__/ReactDOMServerIntegrationHooks-test.js @@ -156,7 +156,7 @@ describe('ReactDOMServerHooks', () => { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); itRenders('multiple times when an updater is called', async render => { @@ -674,7 +674,7 @@ describe('ReactDOMServerHooks', () => { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); }); diff --git a/packages/react-dom/src/__tests__/ReactDOMServerIntegrationUntrustedURL-test.internal.js b/packages/react-dom/src/__tests__/ReactDOMServerIntegrationUntrustedURL-test.internal.js index 0148249bd10f4..9fb48b3bce24c 100644 --- a/packages/react-dom/src/__tests__/ReactDOMServerIntegrationUntrustedURL-test.internal.js +++ b/packages/react-dom/src/__tests__/ReactDOMServerIntegrationUntrustedURL-test.internal.js @@ -250,7 +250,7 @@ describe('ReactDOMServerIntegration - Untrusted URLs - disableJavaScriptURLs', ( // the first times it is called and then becomes dangerous. toStringCalls++; if (toStringCalls <= expectedToStringCalls) { - return 'https://fb.me/'; + return 'https://reactjs.org/'; } return 'javascript:notfine'; }, @@ -258,7 +258,7 @@ describe('ReactDOMServerIntegration - Untrusted URLs - disableJavaScriptURLs', ( const e = await render(); expect(toStringCalls).toBe(expectedToStringCalls); - expect(e.href).toBe('https://fb.me/'); + expect(e.href).toBe('https://reactjs.org/'); }); it('rejects a javascript protocol href if it is added during an update twice', () => { diff --git a/packages/react-dom/src/__tests__/ReactDOMServerLifecycles-test.js b/packages/react-dom/src/__tests__/ReactDOMServerLifecycles-test.js index 377ced34db988..5f1875f5f431c 100644 --- a/packages/react-dom/src/__tests__/ReactDOMServerLifecycles-test.js +++ b/packages/react-dom/src/__tests__/ReactDOMServerLifecycles-test.js @@ -293,7 +293,7 @@ describe('ReactDOMServerLifecycles', () => { } expect(() => ReactDOMServer.renderToString()).toWarnDev( - 'componentWillMount has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'componentWillMount has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move code from componentWillMount to componentDidMount (preferred in most cases) or the constructor.\n\n' + 'Please update the following components: MyComponent', ); diff --git a/packages/react-dom/src/__tests__/ReactDOMTextarea-test.js b/packages/react-dom/src/__tests__/ReactDOMTextarea-test.js index 92d1142f5b186..4d56f53d9e40c 100644 --- a/packages/react-dom/src/__tests__/ReactDOMTextarea-test.js +++ b/packages/react-dom/src/__tests__/ReactDOMTextarea-test.js @@ -525,7 +525,7 @@ describe('ReactDOMTextarea', () => { '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled textarea ' + 'and remove one of these props. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', ); // No additional warnings are expected diff --git a/packages/react-dom/src/__tests__/ReactDeprecationWarnings-test.internal.js b/packages/react-dom/src/__tests__/ReactDeprecationWarnings-test.internal.js index 5ccbd7e481e4b..f65c6e85e834b 100644 --- a/packages/react-dom/src/__tests__/ReactDeprecationWarnings-test.internal.js +++ b/packages/react-dom/src/__tests__/ReactDeprecationWarnings-test.internal.js @@ -69,7 +69,7 @@ describe('ReactDeprecationWarnings', () => { 'Support for string refs will be removed in a future major release. ' + 'We recommend using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref' + + 'https://reactjs.org/link/strict-mode-string-ref' + '\n in Component (at **)', ); }); @@ -110,7 +110,7 @@ describe('ReactDeprecationWarnings', () => { 'This case cannot be automatically converted to an arrow function. ' + 'We ask you to manually fix this case by using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref', + 'https://reactjs.org/link/strict-mode-string-ref', ]); }); @@ -141,7 +141,7 @@ describe('ReactDeprecationWarnings', () => { 'This case cannot be automatically converted to an arrow function. ' + 'We ask you to manually fix this case by using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref', + 'https://reactjs.org/link/strict-mode-string-ref', ); }); } diff --git a/packages/react-dom/src/__tests__/ReactFunctionComponent-test.js b/packages/react-dom/src/__tests__/ReactFunctionComponent-test.js index c80a05c2113be..8e6d1eaa594e4 100644 --- a/packages/react-dom/src/__tests__/ReactFunctionComponent-test.js +++ b/packages/react-dom/src/__tests__/ReactFunctionComponent-test.js @@ -167,7 +167,7 @@ describe('ReactFunctionComponent', () => { '1. You may be adding a ref to a function component\n' + "2. You may be adding a ref to a component that was not created inside a component's render method\n" + '3. You have multiple copies of React loaded\n' + - 'See https://fb.me/react-refs-must-have-owner for more information.', + 'See https://reactjs.org/link/refs-must-have-owner for more information.', ); }); diff --git a/packages/react-dom/src/__tests__/ReactTestUtils-test.js b/packages/react-dom/src/__tests__/ReactTestUtils-test.js index 20940d7523e50..8b1bccac4416a 100644 --- a/packages/react-dom/src/__tests__/ReactTestUtils-test.js +++ b/packages/react-dom/src/__tests__/ReactTestUtils-test.js @@ -46,7 +46,7 @@ describe('ReactTestUtils', () => { ).toWarnDev( 'ReactTestUtils.mockComponent() is deprecated. ' + 'Use shallow rendering or jest.mock() instead.\n\n' + - 'See https://fb.me/test-utils-mock-component for more information.', + 'See https://reactjs.org/link/test-utils-mock-component for more information.', {withoutStack: true}, ); diff --git a/packages/react-dom/src/__tests__/findDOMNode-test.js b/packages/react-dom/src/__tests__/findDOMNode-test.js index 9aaa65088e6c4..c634886e8f8df 100644 --- a/packages/react-dom/src/__tests__/findDOMNode-test.js +++ b/packages/react-dom/src/__tests__/findDOMNode-test.js @@ -122,7 +122,7 @@ describe('findDOMNode', () => { 'findDOMNode was passed an instance of ContainsStrictModeChild which renders StrictMode children. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node' + + 'https://reactjs.org/link/strict-mode-find-node' + '\n in div (at **)' + '\n in ContainsStrictModeChild (at **)', ]); @@ -151,7 +151,7 @@ describe('findDOMNode', () => { 'findDOMNode was passed an instance of IsInStrictMode which is inside StrictMode. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node' + + 'https://reactjs.org/link/strict-mode-find-node' + '\n in div (at **)' + '\n in IsInStrictMode (at **)', ]); diff --git a/packages/react-dom/src/__tests__/multiple-copies-of-react-test.js b/packages/react-dom/src/__tests__/multiple-copies-of-react-test.js index 280af615cdf78..5e2d75b657088 100644 --- a/packages/react-dom/src/__tests__/multiple-copies-of-react-test.js +++ b/packages/react-dom/src/__tests__/multiple-copies-of-react-test.js @@ -30,7 +30,7 @@ describe('when different React version is used with string ref', () => { '1. You may be adding a ref to a function component\n' + "2. You may be adding a ref to a component that was not created inside a component's render method\n" + '3. You have multiple copies of React loaded\n' + - 'See https://fb.me/react-refs-must-have-owner for more information.', + 'See https://reactjs.org/link/refs-must-have-owner for more information.', ); }); }); diff --git a/packages/react-dom/src/__tests__/refs-test.js b/packages/react-dom/src/__tests__/refs-test.js index 972e454e398c8..4b616c1ae4cfa 100644 --- a/packages/react-dom/src/__tests__/refs-test.js +++ b/packages/react-dom/src/__tests__/refs-test.js @@ -458,7 +458,7 @@ describe('creating element with ref in constructor', () => { '1. You may be adding a ref to a function component\n' + "2. You may be adding a ref to a component that was not created inside a component's render method\n" + '3. You have multiple copies of React loaded\n' + - 'See https://fb.me/react-refs-must-have-owner for more information.', + 'See https://reactjs.org/link/refs-must-have-owner for more information.', ); }); }); diff --git a/packages/react-dom/src/client/ReactDOM.js b/packages/react-dom/src/client/ReactDOM.js index a0861bc5d6a0a..5daeef818161f 100644 --- a/packages/react-dom/src/client/ReactDOM.js +++ b/packages/react-dom/src/client/ReactDOM.js @@ -94,7 +94,7 @@ if (__DEV__) { ) { console.error( 'React depends on Map and Set built-in types. Make sure that you load a ' + - 'polyfill in older browsers. https://fb.me/react-polyfills', + 'polyfill in older browsers. https://reactjs.org/link/react-polyfills', ); } } @@ -238,10 +238,10 @@ if (__DEV__) { console.info( '%cDownload the React DevTools ' + 'for a better development experience: ' + - 'https://fb.me/react-devtools' + + 'https://reactjs.org/link/react-devtools' + (protocol === 'file:' ? '\nYou might need to use a local HTTP server (instead of file://): ' + - 'https://fb.me/react-devtools-faq' + 'https://reactjs.org/link/react-devtools-faq' : ''), 'font-weight:bold', ); diff --git a/packages/react-dom/src/client/ReactDOMInput.js b/packages/react-dom/src/client/ReactDOMInput.js index e503b75a95469..3bfdd8b01f643 100644 --- a/packages/react-dom/src/client/ReactDOMInput.js +++ b/packages/react-dom/src/client/ReactDOMInput.js @@ -86,7 +86,7 @@ export function initWrapperState(element: Element, props: Object) { '(specify either the checked prop, or the defaultChecked prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', getCurrentFiberOwnerNameInDevOrNull() || 'A component', props.type, ); @@ -103,7 +103,7 @@ export function initWrapperState(element: Element, props: Object) { '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', getCurrentFiberOwnerNameInDevOrNull() || 'A component', props.type, ); @@ -147,7 +147,7 @@ export function updateWrapper(element: Element, props: Object) { 'This is likely caused by the value changing from undefined to ' + 'a defined value, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components', ); didWarnUncontrolledToControlled = true; } @@ -161,7 +161,7 @@ export function updateWrapper(element: Element, props: Object) { 'This is likely caused by the value changing from a defined to ' + 'undefined, which should not happen. ' + 'Decide between using a controlled or uncontrolled input ' + - 'element for the lifetime of the component. More info: https://fb.me/react-controlled-components', + 'element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components', ); didWarnControlledToUncontrolled = true; } diff --git a/packages/react-dom/src/client/ReactDOMSelect.js b/packages/react-dom/src/client/ReactDOMSelect.js index d97e01be0ab60..1efca61905b4a 100644 --- a/packages/react-dom/src/client/ReactDOMSelect.js +++ b/packages/react-dom/src/client/ReactDOMSelect.js @@ -159,7 +159,7 @@ export function initWrapperState(element: Element, props: Object) { '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled select ' + 'element and remove one of these props. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', ); didWarnValueDefaultValue = true; } diff --git a/packages/react-dom/src/client/ReactDOMTextarea.js b/packages/react-dom/src/client/ReactDOMTextarea.js index a37c36b94efd8..24fb591fcd8af 100644 --- a/packages/react-dom/src/client/ReactDOMTextarea.js +++ b/packages/react-dom/src/client/ReactDOMTextarea.js @@ -76,7 +76,7 @@ export function initWrapperState(element: Element, props: Object) { '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled textarea ' + 'and remove one of these props. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', getCurrentFiberOwnerNameInDevOrNull() || 'A component', ); didWarnValDefaultVal = true; diff --git a/packages/react-dom/src/server/ReactPartialRenderer.js b/packages/react-dom/src/server/ReactPartialRenderer.js index 1754555dd5493..3ef3137871661 100644 --- a/packages/react-dom/src/server/ReactPartialRenderer.js +++ b/packages/react-dom/src/server/ReactPartialRenderer.js @@ -591,7 +591,7 @@ function resolve( console.warn( // keep this warning in sync with ReactStrictModeWarning.js 'componentWillMount has been renamed, and is not recommended for use. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move code from componentWillMount to componentDidMount (preferred in most cases) ' + 'or the constructor.\n' + '\nPlease update the following components: %s', @@ -1398,7 +1398,7 @@ class ReactDOMServerRenderer { '(specify either the checked prop, or the defaultChecked prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', 'A component', props.type, ); @@ -1415,7 +1415,7 @@ class ReactDOMServerRenderer { '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled input ' + 'element and remove one of these props. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', 'A component', props.type, ); @@ -1448,7 +1448,7 @@ class ReactDOMServerRenderer { '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled textarea ' + 'and remove one of these props. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', ); didWarnDefaultTextareaValue = true; } @@ -1525,7 +1525,7 @@ class ReactDOMServerRenderer { '(specify either the value prop, or the defaultValue prop, but not ' + 'both). Decide between using a controlled or uncontrolled select ' + 'element and remove one of these props. More info: ' + - 'https://fb.me/react-controlled-components', + 'https://reactjs.org/link/controlled-components', ); didWarnDefaultSelectValue = true; } diff --git a/packages/react-dom/src/server/ReactPartialRendererHooks.js b/packages/react-dom/src/server/ReactPartialRendererHooks.js index 8cc7be4716205..302a6682b443f 100644 --- a/packages/react-dom/src/server/ReactPartialRendererHooks.js +++ b/packages/react-dom/src/server/ReactPartialRendererHooks.js @@ -74,7 +74,7 @@ function resolveCurrentlyRenderingComponent(): Object { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); if (__DEV__) { if (isInHookUserCodeInDev) { @@ -82,7 +82,7 @@ function resolveCurrentlyRenderingComponent(): Object { 'Do not call Hooks inside useEffect(...), useMemo(...), or other built-in Hooks. ' + 'You can only call Hooks at the top level of your React function. ' + 'For more information, see ' + - 'https://fb.me/rules-of-hooks', + 'https://reactjs.org/link/rules-of-hooks', ); } } @@ -403,7 +403,7 @@ export function useLayoutEffect( 'to a mismatch between the initial, non-hydrated UI and the intended ' + 'UI. To avoid this, useLayoutEffect should only be used in ' + 'components that render exclusively on the client. ' + - 'See https://fb.me/react-uselayouteffect-ssr for common fixes.', + 'See https://reactjs.org/link/uselayouteffect-ssr for common fixes.', ); } } diff --git a/packages/react-dom/src/shared/ReactDOMInvalidARIAHook.js b/packages/react-dom/src/shared/ReactDOMInvalidARIAHook.js index cceea9758c57f..89cc3f271fbba 100644 --- a/packages/react-dom/src/shared/ReactDOMInvalidARIAHook.js +++ b/packages/react-dom/src/shared/ReactDOMInvalidARIAHook.js @@ -95,14 +95,14 @@ function warnInvalidARIAProps(type, props) { if (invalidProps.length === 1) { console.error( 'Invalid aria prop %s on <%s> tag. ' + - 'For details, see https://fb.me/invalid-aria-prop', + 'For details, see https://reactjs.org/link/invalid-aria-props', unknownPropString, type, ); } else if (invalidProps.length > 1) { console.error( 'Invalid aria props %s on <%s> tag. ' + - 'For details, see https://fb.me/invalid-aria-prop', + 'For details, see https://reactjs.org/link/invalid-aria-props', unknownPropString, type, ); diff --git a/packages/react-dom/src/shared/ReactDOMUnknownPropertyHook.js b/packages/react-dom/src/shared/ReactDOMUnknownPropertyHook.js index 8069f7cb185ab..ad4be4b5fdea7 100644 --- a/packages/react-dom/src/shared/ReactDOMUnknownPropertyHook.js +++ b/packages/react-dom/src/shared/ReactDOMUnknownPropertyHook.js @@ -256,7 +256,7 @@ const warnUnknownProperties = function(type, props, eventRegistry) { console.error( 'Invalid value for prop %s on <%s> tag. Either remove it from the element, ' + 'or pass a string or number value to keep it in the DOM. ' + - 'For details, see https://fb.me/react-attribute-behavior', + 'For details, see https://reactjs.org/link/attribute-behavior ', unknownPropString, type, ); @@ -264,7 +264,7 @@ const warnUnknownProperties = function(type, props, eventRegistry) { console.error( 'Invalid values for props %s on <%s> tag. Either remove them from the element, ' + 'or pass a string or number value to keep them in the DOM. ' + - 'For details, see https://fb.me/react-attribute-behavior', + 'For details, see https://reactjs.org/link/attribute-behavior ', unknownPropString, type, ); diff --git a/packages/react-dom/src/shared/assertValidProps.js b/packages/react-dom/src/shared/assertValidProps.js index b944c7956b397..26ed1cd958175 100644 --- a/packages/react-dom/src/shared/assertValidProps.js +++ b/packages/react-dom/src/shared/assertValidProps.js @@ -33,7 +33,7 @@ function assertValidProps(tag: string, props: ?Object) { typeof props.dangerouslySetInnerHTML === 'object' && HTML in props.dangerouslySetInnerHTML, '`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. ' + - 'Please visit https://fb.me/react-invariant-dangerously-set-inner-html ' + + 'Please visit https://reactjs.org/link/dangerously-set-inner-html ' + 'for more information.', ); } diff --git a/packages/react-dom/src/test-utils/ReactTestUtils.js b/packages/react-dom/src/test-utils/ReactTestUtils.js index 52ad2621cdebc..f281438e12288 100644 --- a/packages/react-dom/src/test-utils/ReactTestUtils.js +++ b/packages/react-dom/src/test-utils/ReactTestUtils.js @@ -324,7 +324,7 @@ function mockComponent(module, mockTagName) { console.warn( 'ReactTestUtils.mockComponent() is deprecated. ' + 'Use shallow rendering or jest.mock() instead.\n\n' + - 'See https://fb.me/test-utils-mock-component for more information.', + 'See https://reactjs.org/link/test-utils-mock-component for more information.', ); } } diff --git a/packages/react-native-renderer/src/__tests__/ReactFabric-test.internal.js b/packages/react-native-renderer/src/__tests__/ReactFabric-test.internal.js index e1a6b07c2ead9..026c3b4d38d89 100644 --- a/packages/react-native-renderer/src/__tests__/ReactFabric-test.internal.js +++ b/packages/react-native-renderer/src/__tests__/ReactFabric-test.internal.js @@ -771,7 +771,7 @@ describe('ReactFabric', () => { 'findHostInstance_DEPRECATED was passed an instance of ContainsStrictModeChild which renders StrictMode children. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node' + + 'https://reactjs.org/link/strict-mode-find-node' + '\n in RCTView (at **)' + '\n in ContainsStrictModeChild (at **)', ]); @@ -808,7 +808,7 @@ describe('ReactFabric', () => { 'findHostInstance_DEPRECATED was passed an instance of IsInStrictMode which is inside StrictMode. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node' + + 'https://reactjs.org/link/strict-mode-find-node' + '\n in RCTView (at **)' + '\n in IsInStrictMode (at **)', ]); @@ -842,7 +842,7 @@ describe('ReactFabric', () => { 'findNodeHandle was passed an instance of ContainsStrictModeChild which renders StrictMode children. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node' + + 'https://reactjs.org/link/strict-mode-find-node' + '\n in RCTView (at **)' + '\n in ContainsStrictModeChild (at **)', ]); @@ -877,7 +877,7 @@ describe('ReactFabric', () => { 'findNodeHandle was passed an instance of IsInStrictMode which is inside StrictMode. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node' + + 'https://reactjs.org/link/strict-mode-find-node' + '\n in RCTView (at **)' + '\n in IsInStrictMode (at **)', ]); diff --git a/packages/react-native-renderer/src/__tests__/ReactNativeMount-test.internal.js b/packages/react-native-renderer/src/__tests__/ReactNativeMount-test.internal.js index 3022b58333a45..894d4c8aa134f 100644 --- a/packages/react-native-renderer/src/__tests__/ReactNativeMount-test.internal.js +++ b/packages/react-native-renderer/src/__tests__/ReactNativeMount-test.internal.js @@ -481,7 +481,7 @@ describe('ReactNative', () => { 'findHostInstance_DEPRECATED was passed an instance of ContainsStrictModeChild which renders StrictMode children. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node' + + 'https://reactjs.org/link/strict-mode-find-node' + '\n in RCTView (at **)' + '\n in ContainsStrictModeChild (at **)', ]); @@ -518,7 +518,7 @@ describe('ReactNative', () => { 'findHostInstance_DEPRECATED was passed an instance of IsInStrictMode which is inside StrictMode. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node' + + 'https://reactjs.org/link/strict-mode-find-node' + '\n in RCTView (at **)' + '\n in IsInStrictMode (at **)', ]); @@ -552,7 +552,7 @@ describe('ReactNative', () => { 'findNodeHandle was passed an instance of ContainsStrictModeChild which renders StrictMode children. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node' + + 'https://reactjs.org/link/strict-mode-find-node' + '\n in RCTView (at **)' + '\n in ContainsStrictModeChild (at **)', ]); @@ -587,7 +587,7 @@ describe('ReactNative', () => { 'findNodeHandle was passed an instance of IsInStrictMode which is inside StrictMode. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node' + + 'https://reactjs.org/link/strict-mode-find-node' + '\n in RCTView (at **)' + '\n in IsInStrictMode (at **)', ]); diff --git a/packages/react-native-renderer/src/legacy-events/SyntheticEvent.js b/packages/react-native-renderer/src/legacy-events/SyntheticEvent.js index b9e731aa2acdd..a439f8eaa4367 100644 --- a/packages/react-native-renderer/src/legacy-events/SyntheticEvent.js +++ b/packages/react-native-renderer/src/legacy-events/SyntheticEvent.js @@ -289,7 +289,7 @@ function getPooledWarningPropertyDefinition(propName, getVal) { "This synthetic event is reused for performance reasons. If you're seeing this, " + "you're %s `%s` on a released/nullified synthetic event. %s. " + 'If you must keep the original synthetic event around, use event.persist(). ' + - 'See https://fb.me/react-event-pooling for more information.', + 'See https://reactjs.org/link/event-pooling for more information.', action, propName, result, diff --git a/packages/react-reconciler/src/ReactChildFiber.new.js b/packages/react-reconciler/src/ReactChildFiber.new.js index 3bef3545fc3a2..776cb014b77d4 100644 --- a/packages/react-reconciler/src/ReactChildFiber.new.js +++ b/packages/react-reconciler/src/ReactChildFiber.new.js @@ -96,7 +96,7 @@ if (__DEV__) { console.error( 'Each child in a list should have a unique ' + - '"key" prop. See https://fb.me/react-warning-keys for ' + + '"key" prop. See https://reactjs.org/link/warning-keys for ' + 'more information.', ); }; @@ -137,7 +137,7 @@ function coerceRef( 'will be removed in a future major release. We recommend using ' + 'useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref', + 'https://reactjs.org/link/strict-mode-string-ref', componentName, mixedRef, ); @@ -147,7 +147,7 @@ function coerceRef( 'String refs are a source of potential bugs and should be avoided. ' + 'We recommend using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref', + 'https://reactjs.org/link/strict-mode-string-ref', mixedRef, ); } @@ -166,7 +166,7 @@ function coerceRef( 'Function components cannot have string refs. ' + 'We recommend using useRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref', + 'https://reactjs.org/link/strict-mode-string-ref', ); inst = ownerFiber.stateNode; } @@ -212,7 +212,7 @@ function coerceRef( '1. You may be adding a ref to a function component\n' + "2. You may be adding a ref to a component that was not created inside a component's render method\n" + '3. You have multiple copies of React loaded\n' + - 'See https://fb.me/react-refs-must-have-owner for more information.', + 'See https://reactjs.org/link/refs-must-have-owner for more information.', mixedRef, ); } diff --git a/packages/react-reconciler/src/ReactChildFiber.old.js b/packages/react-reconciler/src/ReactChildFiber.old.js index 6af9a6ab9fee2..5ba77f9313ad4 100644 --- a/packages/react-reconciler/src/ReactChildFiber.old.js +++ b/packages/react-reconciler/src/ReactChildFiber.old.js @@ -96,7 +96,7 @@ if (__DEV__) { console.error( 'Each child in a list should have a unique ' + - '"key" prop. See https://fb.me/react-warning-keys for ' + + '"key" prop. See https://reactjs.org/link/warning-keys for ' + 'more information.', ); }; @@ -137,7 +137,7 @@ function coerceRef( 'will be removed in a future major release. We recommend using ' + 'useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref', + 'https://reactjs.org/link/strict-mode-string-ref', componentName, mixedRef, ); @@ -147,7 +147,7 @@ function coerceRef( 'String refs are a source of potential bugs and should be avoided. ' + 'We recommend using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref', + 'https://reactjs.org/link/strict-mode-string-ref', mixedRef, ); } @@ -166,7 +166,7 @@ function coerceRef( 'Function components cannot have string refs. ' + 'We recommend using useRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref', + 'https://reactjs.org/link/strict-mode-string-ref', ); inst = ownerFiber.stateNode; } @@ -212,7 +212,7 @@ function coerceRef( '1. You may be adding a ref to a function component\n' + "2. You may be adding a ref to a component that was not created inside a component's render method\n" + '3. You have multiple copies of React loaded\n' + - 'See https://fb.me/react-refs-must-have-owner for more information.', + 'See https://reactjs.org/link/refs-must-have-owner for more information.', mixedRef, ); } diff --git a/packages/react-reconciler/src/ReactFiberClassComponent.new.js b/packages/react-reconciler/src/ReactFiberClassComponent.new.js index 5886d3f4cb807..0c94bd9441c90 100644 --- a/packages/react-reconciler/src/ReactFiberClassComponent.new.js +++ b/packages/react-reconciler/src/ReactFiberClassComponent.new.js @@ -729,7 +729,7 @@ function constructClassInstance( 'Unsafe legacy lifecycles will not be called for components using new component APIs.\n\n' + '%s uses %s but also contains the following legacy lifecycles:%s%s%s\n\n' + 'The above lifecycles should be removed. Learn more about this warning here:\n' + - 'https://fb.me/react-unsafe-component-lifecycles', + 'https://reactjs.org/link/unsafe-component-lifecycles', componentName, newApiName, foundWillMountName !== null ? `\n ${foundWillMountName}` : '', diff --git a/packages/react-reconciler/src/ReactFiberClassComponent.old.js b/packages/react-reconciler/src/ReactFiberClassComponent.old.js index ed544db392fc3..68834e49a1d50 100644 --- a/packages/react-reconciler/src/ReactFiberClassComponent.old.js +++ b/packages/react-reconciler/src/ReactFiberClassComponent.old.js @@ -729,7 +729,7 @@ function constructClassInstance( 'Unsafe legacy lifecycles will not be called for components using new component APIs.\n\n' + '%s uses %s but also contains the following legacy lifecycles:%s%s%s\n\n' + 'The above lifecycles should be removed. Learn more about this warning here:\n' + - 'https://fb.me/react-unsafe-component-lifecycles', + 'https://reactjs.org/link/unsafe-component-lifecycles', componentName, newApiName, foundWillMountName !== null ? `\n ${foundWillMountName}` : '', diff --git a/packages/react-reconciler/src/ReactFiberCommitWork.new.js b/packages/react-reconciler/src/ReactFiberCommitWork.new.js index f086e47cf93b1..d8f006e4b116a 100644 --- a/packages/react-reconciler/src/ReactFiberCommitWork.new.js +++ b/packages/react-reconciler/src/ReactFiberCommitWork.new.js @@ -408,7 +408,7 @@ function commitHookEffectListMount(tag: HookEffectTag, finishedWork: Fiber) { ' }\n' + ' fetchData();\n' + `}, [someId]); // Or [] if effect doesn't need props or state\n\n` + - 'Learn more about data fetching with Hooks: https://fb.me/react-hooks-data-fetching'; + 'Learn more about data fetching with Hooks: https://reactjs.org/link/hooks-data-fetching'; } else { addendum = ' You returned: ' + destroy; } diff --git a/packages/react-reconciler/src/ReactFiberCommitWork.old.js b/packages/react-reconciler/src/ReactFiberCommitWork.old.js index 8e280e1600510..0fb1f942559ec 100644 --- a/packages/react-reconciler/src/ReactFiberCommitWork.old.js +++ b/packages/react-reconciler/src/ReactFiberCommitWork.old.js @@ -359,7 +359,7 @@ function commitHookEffectListMount(tag: number, finishedWork: Fiber) { ' }\n' + ' fetchData();\n' + `}, [someId]); // Or [] if effect doesn't need props or state\n\n` + - 'Learn more about data fetching with Hooks: https://fb.me/react-hooks-data-fetching'; + 'Learn more about data fetching with Hooks: https://reactjs.org/link/hooks-data-fetching'; } else { addendum = ' You returned: ' + destroy; } diff --git a/packages/react-reconciler/src/ReactFiberDevToolsHook.new.js b/packages/react-reconciler/src/ReactFiberDevToolsHook.new.js index cf1bb7a9cf9c7..9664424c1f0d0 100644 --- a/packages/react-reconciler/src/ReactFiberDevToolsHook.new.js +++ b/packages/react-reconciler/src/ReactFiberDevToolsHook.new.js @@ -40,7 +40,7 @@ export function injectInternals(internals: Object): boolean { console.error( 'The installed version of React DevTools is too old and will not work ' + 'with the current version of React. Please update React DevTools. ' + - 'https://fb.me/react-devtools', + 'https://reactjs.org/link/react-devtools', ); } // DevTools exists, even though it doesn't support Fiber. diff --git a/packages/react-reconciler/src/ReactFiberDevToolsHook.old.js b/packages/react-reconciler/src/ReactFiberDevToolsHook.old.js index cf1bb7a9cf9c7..9664424c1f0d0 100644 --- a/packages/react-reconciler/src/ReactFiberDevToolsHook.old.js +++ b/packages/react-reconciler/src/ReactFiberDevToolsHook.old.js @@ -40,7 +40,7 @@ export function injectInternals(internals: Object): boolean { console.error( 'The installed version of React DevTools is too old and will not work ' + 'with the current version of React. Please update React DevTools. ' + - 'https://fb.me/react-devtools', + 'https://reactjs.org/link/react-devtools', ); } // DevTools exists, even though it doesn't support Fiber. diff --git a/packages/react-reconciler/src/ReactFiberErrorLogger.js b/packages/react-reconciler/src/ReactFiberErrorLogger.js index 0f3cd24ab4b5a..a76c65e4d3b4a 100644 --- a/packages/react-reconciler/src/ReactFiberErrorLogger.js +++ b/packages/react-reconciler/src/ReactFiberErrorLogger.js @@ -65,7 +65,7 @@ export function logCapturedError( } else { errorBoundaryMessage = 'Consider adding an error boundary to your tree to customize error handling behavior.\n' + - 'Visit https://fb.me/react-error-boundaries to learn more about error boundaries.'; + 'Visit https://reactjs.org/link/error-boundaries to learn more about error boundaries.'; } const combinedMessage = `${componentNameMessage}\n${componentStack}\n\n` + diff --git a/packages/react-reconciler/src/ReactFiberHooks.new.js b/packages/react-reconciler/src/ReactFiberHooks.new.js index 99f367f606873..7a399fac8a9d1 100644 --- a/packages/react-reconciler/src/ReactFiberHooks.new.js +++ b/packages/react-reconciler/src/ReactFiberHooks.new.js @@ -279,7 +279,7 @@ function warnOnHookMismatchInDev(currentHookName: HookType) { console.error( 'React has detected a change in the order of Hooks called by %s. ' + 'This will lead to bugs and errors if not fixed. ' + - 'For more information, read the Rules of Hooks: https://fb.me/rules-of-hooks\n\n' + + 'For more information, read the Rules of Hooks: https://reactjs.org/link/rules-of-hooks\n\n' + ' Previous render Next render\n' + ' ------------------------------------------------------\n' + '%s' + @@ -300,7 +300,7 @@ function throwInvalidHookError() { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); } @@ -1908,7 +1908,7 @@ if (__DEV__) { 'Do not call Hooks inside useEffect(...), useMemo(...), or other built-in Hooks. ' + 'You can only call Hooks at the top level of your React function. ' + 'For more information, see ' + - 'https://fb.me/rules-of-hooks', + 'https://reactjs.org/link/rules-of-hooks', ); }; diff --git a/packages/react-reconciler/src/ReactFiberHooks.old.js b/packages/react-reconciler/src/ReactFiberHooks.old.js index 380524df9aad6..3928337b73393 100644 --- a/packages/react-reconciler/src/ReactFiberHooks.old.js +++ b/packages/react-reconciler/src/ReactFiberHooks.old.js @@ -278,7 +278,7 @@ function warnOnHookMismatchInDev(currentHookName: HookType) { console.error( 'React has detected a change in the order of Hooks called by %s. ' + 'This will lead to bugs and errors if not fixed. ' + - 'For more information, read the Rules of Hooks: https://fb.me/rules-of-hooks\n\n' + + 'For more information, read the Rules of Hooks: https://reactjs.org/link/rules-of-hooks\n\n' + ' Previous render Next render\n' + ' ------------------------------------------------------\n' + '%s' + @@ -299,7 +299,7 @@ function throwInvalidHookError() { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); } @@ -1906,7 +1906,7 @@ if (__DEV__) { 'Do not call Hooks inside useEffect(...), useMemo(...), or other built-in Hooks. ' + 'You can only call Hooks at the top level of your React function. ' + 'For more information, see ' + - 'https://fb.me/rules-of-hooks', + 'https://reactjs.org/link/rules-of-hooks', ); }; diff --git a/packages/react-reconciler/src/ReactFiberReconciler.new.js b/packages/react-reconciler/src/ReactFiberReconciler.new.js index f2f1187319b82..befd70866dc53 100644 --- a/packages/react-reconciler/src/ReactFiberReconciler.new.js +++ b/packages/react-reconciler/src/ReactFiberReconciler.new.js @@ -206,7 +206,7 @@ function findHostInstanceWithWarning( '%s was passed an instance of %s which is inside StrictMode. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node', + 'https://reactjs.org/link/strict-mode-find-node', methodName, methodName, componentName, @@ -217,7 +217,7 @@ function findHostInstanceWithWarning( '%s was passed an instance of %s which renders StrictMode children. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node', + 'https://reactjs.org/link/strict-mode-find-node', methodName, methodName, componentName, diff --git a/packages/react-reconciler/src/ReactFiberReconciler.old.js b/packages/react-reconciler/src/ReactFiberReconciler.old.js index b272f6147ed55..d2cecfed4976a 100644 --- a/packages/react-reconciler/src/ReactFiberReconciler.old.js +++ b/packages/react-reconciler/src/ReactFiberReconciler.old.js @@ -206,7 +206,7 @@ function findHostInstanceWithWarning( '%s was passed an instance of %s which is inside StrictMode. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node', + 'https://reactjs.org/link/strict-mode-find-node', methodName, methodName, componentName, @@ -217,7 +217,7 @@ function findHostInstanceWithWarning( '%s was passed an instance of %s which renders StrictMode children. ' + 'Instead, add a ref directly to the element you want to reference. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-find-node', + 'https://reactjs.org/link/strict-mode-find-node', methodName, methodName, componentName, diff --git a/packages/react-reconciler/src/ReactFiberWorkLoop.new.js b/packages/react-reconciler/src/ReactFiberWorkLoop.new.js index 87da91d58c5f4..cc259ca099145 100644 --- a/packages/react-reconciler/src/ReactFiberWorkLoop.new.js +++ b/packages/react-reconciler/src/ReactFiberWorkLoop.new.js @@ -3411,7 +3411,7 @@ function warnAboutRenderPhaseUpdatesInDEV(fiber) { console.error( 'Cannot update a component (`%s`) while rendering a ' + 'different component (`%s`). To locate the bad setState() call inside `%s`, ' + - 'follow the stack trace as described in https://fb.me/setstate-in-render', + 'follow the stack trace as described in https://reactjs.org/link/setstate-in-render', setStateComponentName, renderingComponentName, renderingComponentName, @@ -3494,7 +3494,7 @@ export function warnIfNotCurrentlyActingEffectsInDEV(fiber: Fiber): void { '/* assert on the output */\n\n' + "This ensures that you're testing the behavior the user would see " + 'in the browser.' + - ' Learn more at https://fb.me/react-wrap-tests-with-act', + ' Learn more at https://reactjs.org/link/wrap-tests-with-act', getComponentName(fiber.type), ); } @@ -3522,7 +3522,7 @@ function warnIfNotCurrentlyActingUpdatesInDEV(fiber: Fiber): void { '/* assert on the output */\n\n' + "This ensures that you're testing the behavior the user would see " + 'in the browser.' + - ' Learn more at https://fb.me/react-wrap-tests-with-act', + ' Learn more at https://reactjs.org/link/wrap-tests-with-act', getComponentName(fiber.type), ); } finally { @@ -3560,7 +3560,7 @@ export function warnIfUnmockedScheduler(fiber: Fiber) { // Break up requires to avoid accidentally parsing them as dependencies. "jest.mock('scheduler', () => require" + "('scheduler/unstable_mock'));\n\n" + - 'For more info, visit https://fb.me/react-mock-scheduler', + 'For more info, visit https://reactjs.org/link/mock-scheduler', ); } else if (warnAboutUnmockedScheduler === true) { didWarnAboutUnmockedScheduler = true; @@ -3571,7 +3571,7 @@ export function warnIfUnmockedScheduler(fiber: Fiber) { // Break up requires to avoid accidentally parsing them as dependencies. "jest.mock('scheduler', () => require" + "('scheduler/unstable_mock'));\n\n" + - 'For more info, visit https://fb.me/react-mock-scheduler', + 'For more info, visit https://reactjs.org/link/mock-scheduler', ); } } diff --git a/packages/react-reconciler/src/ReactFiberWorkLoop.old.js b/packages/react-reconciler/src/ReactFiberWorkLoop.old.js index 84188fea37427..2889bd751c782 100644 --- a/packages/react-reconciler/src/ReactFiberWorkLoop.old.js +++ b/packages/react-reconciler/src/ReactFiberWorkLoop.old.js @@ -3301,7 +3301,7 @@ function warnAboutRenderPhaseUpdatesInDEV(fiber) { console.error( 'Cannot update a component (`%s`) while rendering a ' + 'different component (`%s`). To locate the bad setState() call inside `%s`, ' + - 'follow the stack trace as described in https://fb.me/setstate-in-render', + 'follow the stack trace as described in https://reactjs.org/link/setstate-in-render', setStateComponentName, renderingComponentName, renderingComponentName, @@ -3384,7 +3384,7 @@ export function warnIfNotCurrentlyActingEffectsInDEV(fiber: Fiber): void { '/* assert on the output */\n\n' + "This ensures that you're testing the behavior the user would see " + 'in the browser.' + - ' Learn more at https://fb.me/react-wrap-tests-with-act', + ' Learn more at https://reactjs.org/link/wrap-tests-with-act', getComponentName(fiber.type), ); } @@ -3412,7 +3412,7 @@ function warnIfNotCurrentlyActingUpdatesInDEV(fiber: Fiber): void { '/* assert on the output */\n\n' + "This ensures that you're testing the behavior the user would see " + 'in the browser.' + - ' Learn more at https://fb.me/react-wrap-tests-with-act', + ' Learn more at https://reactjs.org/link/wrap-tests-with-act', getComponentName(fiber.type), ); } finally { @@ -3450,7 +3450,7 @@ export function warnIfUnmockedScheduler(fiber: Fiber) { // Break up requires to avoid accidentally parsing them as dependencies. "jest.mock('scheduler', () => require" + "('scheduler/unstable_mock'));\n\n" + - 'For more info, visit https://fb.me/react-mock-scheduler', + 'For more info, visit https://reactjs.org/link/mock-scheduler', ); } else if (warnAboutUnmockedScheduler === true) { didWarnAboutUnmockedScheduler = true; @@ -3461,7 +3461,7 @@ export function warnIfUnmockedScheduler(fiber: Fiber) { // Break up requires to avoid accidentally parsing them as dependencies. "jest.mock('scheduler', () => require" + "('scheduler/unstable_mock'));\n\n" + - 'For more info, visit https://fb.me/react-mock-scheduler', + 'For more info, visit https://reactjs.org/link/mock-scheduler', ); } } diff --git a/packages/react-reconciler/src/ReactStrictModeWarnings.new.js b/packages/react-reconciler/src/ReactStrictModeWarnings.new.js index 14ab8db576e62..5dd09a8cc80da 100644 --- a/packages/react-reconciler/src/ReactStrictModeWarnings.new.js +++ b/packages/react-reconciler/src/ReactStrictModeWarnings.new.js @@ -193,7 +193,7 @@ if (__DEV__) { ); console.error( 'Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move code with side effects to componentDidMount, and set initial state in the constructor.\n' + '\nPlease update the following components: %s', sortedNames, @@ -207,11 +207,11 @@ if (__DEV__) { console.error( 'Using UNSAFE_componentWillReceiveProps in strict mode is not recommended ' + 'and may indicate bugs in your code. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move data fetching code or side effects to componentDidUpdate.\n' + "* If you're updating state whenever props change, " + 'refactor your code to use memoization techniques or move it to ' + - 'static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state\n' + + 'static getDerivedStateFromProps. Learn more at: https://reactjs.org/link/derived-state\n' + '\nPlease update the following components: %s', sortedNames, ); @@ -224,7 +224,7 @@ if (__DEV__) { console.error( 'Using UNSAFE_componentWillUpdate in strict mode is not recommended ' + 'and may indicate bugs in your code. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move data fetching code or side effects to componentDidUpdate.\n' + '\nPlease update the following components: %s', sortedNames, @@ -236,7 +236,7 @@ if (__DEV__) { console.warn( 'componentWillMount has been renamed, and is not recommended for use. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move code with side effects to componentDidMount, and set initial state in the constructor.\n' + '* Rename componentWillMount to UNSAFE_componentWillMount to suppress ' + 'this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. ' + @@ -254,11 +254,11 @@ if (__DEV__) { console.warn( 'componentWillReceiveProps has been renamed, and is not recommended for use. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move data fetching code or side effects to componentDidUpdate.\n' + "* If you're updating state whenever props change, refactor your " + 'code to use memoization techniques or move it to ' + - 'static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state\n' + + 'static getDerivedStateFromProps. Learn more at: https://reactjs.org/link/derived-state\n' + '* Rename componentWillReceiveProps to UNSAFE_componentWillReceiveProps to suppress ' + 'this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. ' + 'To rename all deprecated lifecycles to their new names, you can run ' + @@ -273,7 +273,7 @@ if (__DEV__) { console.warn( 'componentWillUpdate has been renamed, and is not recommended for use. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move data fetching code or side effects to componentDidUpdate.\n' + '* Rename componentWillUpdate to UNSAFE_componentWillUpdate to suppress ' + 'this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. ' + @@ -346,7 +346,7 @@ if (__DEV__) { '\n\nThe old API will be supported in all 16.x releases, but applications ' + 'using it should migrate to the new version.' + '\n\nPlease update the following components: %s' + - '\n\nLearn more about this warning here: https://fb.me/react-legacy-context', + '\n\nLearn more about this warning here: https://reactjs.org/link/legacy-context', sortedNames, ); } finally { diff --git a/packages/react-reconciler/src/ReactStrictModeWarnings.old.js b/packages/react-reconciler/src/ReactStrictModeWarnings.old.js index 15d86a73b4b78..5cb33579c7be5 100644 --- a/packages/react-reconciler/src/ReactStrictModeWarnings.old.js +++ b/packages/react-reconciler/src/ReactStrictModeWarnings.old.js @@ -193,7 +193,7 @@ if (__DEV__) { ); console.error( 'Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move code with side effects to componentDidMount, and set initial state in the constructor.\n' + '\nPlease update the following components: %s', sortedNames, @@ -207,11 +207,11 @@ if (__DEV__) { console.error( 'Using UNSAFE_componentWillReceiveProps in strict mode is not recommended ' + 'and may indicate bugs in your code. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move data fetching code or side effects to componentDidUpdate.\n' + "* If you're updating state whenever props change, " + 'refactor your code to use memoization techniques or move it to ' + - 'static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state\n' + + 'static getDerivedStateFromProps. Learn more at: https://reactjs.org/link/derived-state\n' + '\nPlease update the following components: %s', sortedNames, ); @@ -224,7 +224,7 @@ if (__DEV__) { console.error( 'Using UNSAFE_componentWillUpdate in strict mode is not recommended ' + 'and may indicate bugs in your code. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move data fetching code or side effects to componentDidUpdate.\n' + '\nPlease update the following components: %s', sortedNames, @@ -236,7 +236,7 @@ if (__DEV__) { console.warn( 'componentWillMount has been renamed, and is not recommended for use. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move code with side effects to componentDidMount, and set initial state in the constructor.\n' + '* Rename componentWillMount to UNSAFE_componentWillMount to suppress ' + 'this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. ' + @@ -254,11 +254,11 @@ if (__DEV__) { console.warn( 'componentWillReceiveProps has been renamed, and is not recommended for use. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move data fetching code or side effects to componentDidUpdate.\n' + "* If you're updating state whenever props change, refactor your " + 'code to use memoization techniques or move it to ' + - 'static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state\n' + + 'static getDerivedStateFromProps. Learn more at: https://reactjs.org/link/derived-state\n' + '* Rename componentWillReceiveProps to UNSAFE_componentWillReceiveProps to suppress ' + 'this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. ' + 'To rename all deprecated lifecycles to their new names, you can run ' + @@ -273,7 +273,7 @@ if (__DEV__) { console.warn( 'componentWillUpdate has been renamed, and is not recommended for use. ' + - 'See https://fb.me/react-unsafe-component-lifecycles for details.\n\n' + + 'See https://reactjs.org/link/unsafe-component-lifecycles for details.\n\n' + '* Move data fetching code or side effects to componentDidUpdate.\n' + '* Rename componentWillUpdate to UNSAFE_componentWillUpdate to suppress ' + 'this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. ' + @@ -346,7 +346,7 @@ if (__DEV__) { '\n\nThe old API will be supported in all 16.x releases, but applications ' + 'using it should migrate to the new version.' + '\n\nPlease update the following components: %s' + - '\n\nLearn more about this warning here: https://fb.me/react-legacy-context', + '\n\nLearn more about this warning here: https://reactjs.org/link/legacy-context', sortedNames, ); } finally { diff --git a/packages/react-reconciler/src/SchedulerWithReactIntegration.new.js b/packages/react-reconciler/src/SchedulerWithReactIntegration.new.js index 18e4ba82ab36c..606a90252077e 100644 --- a/packages/react-reconciler/src/SchedulerWithReactIntegration.new.js +++ b/packages/react-reconciler/src/SchedulerWithReactIntegration.new.js @@ -49,7 +49,7 @@ if (enableSchedulerTracing) { 'example, `react-dom/profiling`) without also replacing the ' + '`scheduler/tracing` module with `scheduler/tracing-profiling`. Your ' + 'bundler might have a setting for aliasing both modules. Learn more at ' + - 'http://fb.me/react-profiling', + 'https://reactjs.org/link/profiling', ); } diff --git a/packages/react-reconciler/src/SchedulerWithReactIntegration.old.js b/packages/react-reconciler/src/SchedulerWithReactIntegration.old.js index 18e4ba82ab36c..606a90252077e 100644 --- a/packages/react-reconciler/src/SchedulerWithReactIntegration.old.js +++ b/packages/react-reconciler/src/SchedulerWithReactIntegration.old.js @@ -49,7 +49,7 @@ if (enableSchedulerTracing) { 'example, `react-dom/profiling`) without also replacing the ' + '`scheduler/tracing` module with `scheduler/tracing-profiling`. Your ' + 'bundler might have a setting for aliasing both modules. Learn more at ' + - 'http://fb.me/react-profiling', + 'https://reactjs.org/link/profiling', ); } diff --git a/packages/react-reconciler/src/__tests__/ReactBlocks-test.js b/packages/react-reconciler/src/__tests__/ReactBlocks-test.js index 06662e63f3ebd..0d28a3359967d 100644 --- a/packages/react-reconciler/src/__tests__/ReactBlocks-test.js +++ b/packages/react-reconciler/src/__tests__/ReactBlocks-test.js @@ -102,7 +102,7 @@ describe('ReactBlocks', () => { }).toErrorDev( 'Warning: Each child in a list should have a unique ' + '"key" prop.\n\nCheck the render method of `User`. See ' + - 'https://fb.me/react-warning-keys for more information.\n' + + 'https://reactjs.org/link/warning-keys for more information.\n' + ' in span (at **)\n' + ' in User (at **)\n' + ' in Suspense (at **)\n' + diff --git a/packages/react-reconciler/src/__tests__/ReactHooks-test.internal.js b/packages/react-reconciler/src/__tests__/ReactHooks-test.internal.js index 129a83f639c81..4c2a39718c9e4 100644 --- a/packages/react-reconciler/src/__tests__/ReactHooks-test.internal.js +++ b/packages/react-reconciler/src/__tests__/ReactHooks-test.internal.js @@ -51,7 +51,7 @@ describe('ReactHooks', () => { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); }); } @@ -906,7 +906,7 @@ describe('ReactHooks', () => { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); // the next round, it does a fresh mount, so should render expect(() => root.update()).not.toThrow( @@ -915,7 +915,7 @@ describe('ReactHooks', () => { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); // and then again, fail expect(() => root.update()).toThrow( @@ -924,7 +924,7 @@ describe('ReactHooks', () => { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); }); @@ -1115,7 +1115,7 @@ describe('ReactHooks', () => { 'Do not call Hooks inside useEffect(...), useMemo(...), or other built-in Hooks', 'Warning: React has detected a change in the order of Hooks called by App. ' + 'This will lead to bugs and errors if not fixed. For more information, ' + - 'read the Rules of Hooks: https://fb.me/rules-of-hooks\n\n' + + 'read the Rules of Hooks: https://reactjs.org/link/rules-of-hooks\n\n' + ' Previous render Next render\n' + ' ------------------------------------------------------\n' + '1. useReducer useReducer\n' + @@ -1573,7 +1573,7 @@ describe('ReactHooks', () => { }).toErrorDev([ 'Warning: React has detected a change in the order of Hooks called by App. ' + 'This will lead to bugs and errors if not fixed. For more information, ' + - 'read the Rules of Hooks: https://fb.me/rules-of-hooks\n\n' + + 'read the Rules of Hooks: https://reactjs.org/link/rules-of-hooks\n\n' + ' Previous render Next render\n' + ' ------------------------------------------------------\n' + `1. ${formatHookNamesToMatchErrorMessage(hookNameA, hookNameB)}\n` + @@ -1624,7 +1624,7 @@ describe('ReactHooks', () => { }).toErrorDev([ 'Warning: React has detected a change in the order of Hooks called by App. ' + 'This will lead to bugs and errors if not fixed. For more information, ' + - 'read the Rules of Hooks: https://fb.me/rules-of-hooks\n\n' + + 'read the Rules of Hooks: https://reactjs.org/link/rules-of-hooks\n\n' + ' Previous render Next render\n' + ' ------------------------------------------------------\n' + `1. ${formatHookNamesToMatchErrorMessage(hookNameA, hookNameA)}\n` + @@ -1704,7 +1704,7 @@ describe('ReactHooks', () => { }).toErrorDev([ 'Warning: React has detected a change in the order of Hooks called by App. ' + 'This will lead to bugs and errors if not fixed. For more information, ' + - 'read the Rules of Hooks: https://fb.me/rules-of-hooks\n\n' + + 'read the Rules of Hooks: https://reactjs.org/link/rules-of-hooks\n\n' + ' Previous render Next render\n' + ' ------------------------------------------------------\n' + `1. ${formatHookNamesToMatchErrorMessage( @@ -1746,7 +1746,7 @@ describe('ReactHooks', () => { }).toErrorDev([ 'Warning: React has detected a change in the order of Hooks called by App. ' + 'This will lead to bugs and errors if not fixed. For more information, ' + - 'read the Rules of Hooks: https://fb.me/rules-of-hooks\n\n' + + 'read the Rules of Hooks: https://reactjs.org/link/rules-of-hooks\n\n' + ' Previous render Next render\n' + ' ------------------------------------------------------\n' + '1. useReducer useState\n' + diff --git a/packages/react-reconciler/src/__tests__/ReactHooksWithNoopRenderer-test.js b/packages/react-reconciler/src/__tests__/ReactHooksWithNoopRenderer-test.js index 7ff61126f648a..39cedad81714e 100644 --- a/packages/react-reconciler/src/__tests__/ReactHooksWithNoopRenderer-test.js +++ b/packages/react-reconciler/src/__tests__/ReactHooksWithNoopRenderer-test.js @@ -162,7 +162,7 @@ describe('ReactHooksWithNoopRenderer', () => { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); // Confirm that a subsequent hook works properly. @@ -192,7 +192,7 @@ describe('ReactHooksWithNoopRenderer', () => { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ), ).toErrorDev( 'Warning: The component appears to be a function component that returns a class instance. ' + @@ -219,7 +219,7 @@ describe('ReactHooksWithNoopRenderer', () => { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); }); @@ -3406,7 +3406,7 @@ describe('ReactHooksWithNoopRenderer', () => { }).toErrorDev([ 'Warning: React has detected a change in the order of Hooks called by App. ' + 'This will lead to bugs and errors if not fixed. For more information, ' + - 'read the Rules of Hooks: https://fb.me/rules-of-hooks\n\n' + + 'read the Rules of Hooks: https://reactjs.org/link/rules-of-hooks\n\n' + ' Previous render Next render\n' + ' ------------------------------------------------------\n' + '1. useState useState\n' + @@ -3502,7 +3502,7 @@ describe('ReactHooksWithNoopRenderer', () => { }).toErrorDev([ 'Warning: React has detected a change in the order of Hooks called by App. ' + 'This will lead to bugs and errors if not fixed. For more information, ' + - 'read the Rules of Hooks: https://fb.me/rules-of-hooks\n\n' + + 'read the Rules of Hooks: https://reactjs.org/link/rules-of-hooks\n\n' + ' Previous render Next render\n' + ' ------------------------------------------------------\n' + '1. useEffect useEffect\n' + diff --git a/packages/react-reconciler/src/__tests__/ReactNewContext-test.js b/packages/react-reconciler/src/__tests__/ReactNewContext-test.js index d0d6e4426f0f2..3f7f4f992955b 100644 --- a/packages/react-reconciler/src/__tests__/ReactNewContext-test.js +++ b/packages/react-reconciler/src/__tests__/ReactNewContext-test.js @@ -1525,7 +1525,7 @@ describe('ReactNewContext', () => { 'You passed: 0.\n\n' + 'Did you call array.map(useContext)? ' + 'Calling Hooks inside a loop is not supported. ' + - 'Learn more at https://fb.me/rules-of-hooks', + 'Learn more at https://reactjs.org/link/rules-of-hooks', ); }); @@ -1543,7 +1543,7 @@ describe('ReactNewContext', () => { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); }); diff --git a/packages/react-reconciler/src/__tests__/ReactTracing-test.internal.js b/packages/react-reconciler/src/__tests__/ReactTracing-test.internal.js index 2f45ad48caf90..3815ec848794c 100644 --- a/packages/react-reconciler/src/__tests__/ReactTracing-test.internal.js +++ b/packages/react-reconciler/src/__tests__/ReactTracing-test.internal.js @@ -22,7 +22,7 @@ describe('ReactTracing', () => { ReactFeatureFlags.enableSchedulerTracing = true; expect(() => require('react-dom')).toThrow( - 'Learn more at http://fb.me/react-profiling', + 'Learn more at https://reactjs.org/link/profiling', ); }); }); diff --git a/packages/react/src/ReactElement.js b/packages/react/src/ReactElement.js index fc2302e7fde10..d157a428dad80 100644 --- a/packages/react/src/ReactElement.js +++ b/packages/react/src/ReactElement.js @@ -61,7 +61,7 @@ function defineKeyPropWarningGetter(props, displayName) { '%s: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + - 'prop. (https://fb.me/react-special-props)', + 'prop. (https://reactjs.org/link/special-props)', displayName, ); } @@ -83,7 +83,7 @@ function defineRefPropWarningGetter(props, displayName) { '%s: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + - 'prop. (https://fb.me/react-special-props)', + 'prop. (https://reactjs.org/link/special-props)', displayName, ); } @@ -113,7 +113,7 @@ function warnIfStringRefCannotBeAutoConverted(config) { 'This case cannot be automatically converted to an arrow function. ' + 'We ask you to manually fix this case by using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref', + 'https://reactjs.org/link/strict-mode-string-ref', componentName, config.ref, ); diff --git a/packages/react/src/ReactElementValidator.js b/packages/react/src/ReactElementValidator.js index 16c5d91184891..b63f454f94036 100644 --- a/packages/react/src/ReactElementValidator.js +++ b/packages/react/src/ReactElementValidator.js @@ -148,7 +148,7 @@ function validateExplicitKey(element, parentType) { setCurrentlyValidatingElement(element); console.error( 'Each child in a list should have a unique "key" prop.' + - '%s%s See https://fb.me/react-warning-keys for more information.', + '%s%s See https://reactjs.org/link/warning-keys for more information.', currentComponentErrorInfo, childOwner, ); diff --git a/packages/react/src/ReactHooks.js b/packages/react/src/ReactHooks.js index 703bafacb9194..d8340e2d14a3e 100644 --- a/packages/react/src/ReactHooks.js +++ b/packages/react/src/ReactHooks.js @@ -31,7 +31,7 @@ function resolveDispatcher() { '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://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.', + 'See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.', ); return dispatcher; } @@ -51,7 +51,7 @@ export function useContext( typeof unstable_observedBits === 'number' && Array.isArray(arguments[2]) ? '\n\nDid you call array.map(useContext)? ' + 'Calling Hooks inside a loop is not supported. ' + - 'Learn more at https://fb.me/rules-of-hooks' + 'Learn more at https://reactjs.org/link/rules-of-hooks' : '', ); } diff --git a/packages/react/src/__tests__/ReactChildren-test.js b/packages/react/src/__tests__/ReactChildren-test.js index bb9aa9c815dcd..d9a1ac3d78701 100644 --- a/packages/react/src/__tests__/ReactChildren-test.js +++ b/packages/react/src/__tests__/ReactChildren-test.js @@ -974,7 +974,7 @@ describe('ReactChildren', () => { ).toErrorDev( 'Warning: ' + 'Each child in a list should have a unique "key" prop.' + - ' See https://fb.me/react-warning-keys for more information.' + + ' See https://reactjs.org/link/warning-keys for more information.' + '\n in ComponentReturningArray (at **)', ); }); @@ -995,7 +995,7 @@ describe('ReactChildren', () => { ).toErrorDev( 'Warning: ' + 'Each child in a list should have a unique "key" prop.' + - ' See https://fb.me/react-warning-keys for more information.', + ' See https://reactjs.org/link/warning-keys for more information.', {withoutStack: true}, // There's nothing on the stack ); }); diff --git a/packages/react/src/__tests__/ReactElement-test.js b/packages/react/src/__tests__/ReactElement-test.js index 6c3d4f6cebae0..fbe500a009b73 100644 --- a/packages/react/src/__tests__/ReactElement-test.js +++ b/packages/react/src/__tests__/ReactElement-test.js @@ -79,7 +79,7 @@ describe('ReactElement', () => { 'Child: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + - 'prop. (https://fb.me/react-special-props)', + 'prop. (https://reactjs.org/link/special-props)', ); }); @@ -91,7 +91,7 @@ describe('ReactElement', () => { 'div: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + - 'prop. (https://fb.me/react-special-props)', + 'prop. (https://reactjs.org/link/special-props)', {withoutStack: true}, ); }); @@ -116,7 +116,7 @@ describe('ReactElement', () => { 'Child: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + - 'prop. (https://fb.me/react-special-props)', + 'prop. (https://reactjs.org/link/special-props)', ); }); diff --git a/packages/react/src/__tests__/ReactElementJSX-test.js b/packages/react/src/__tests__/ReactElementJSX-test.js index fbf9cc7a3ca27..04bf8e1773585 100644 --- a/packages/react/src/__tests__/ReactElementJSX-test.js +++ b/packages/react/src/__tests__/ReactElementJSX-test.js @@ -231,7 +231,7 @@ describe('ReactElement.jsx', () => { 'Child: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + - 'prop. (https://fb.me/react-special-props)', + 'prop. (https://reactjs.org/link/special-props)', ); }); @@ -258,7 +258,7 @@ describe('ReactElement.jsx', () => { 'div: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + - 'prop. (https://fb.me/react-special-props)', + 'prop. (https://reactjs.org/link/special-props)', {withoutStack: true}, ); }); @@ -283,7 +283,7 @@ describe('ReactElement.jsx', () => { 'Child: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + - 'prop. (https://fb.me/react-special-props)', + 'prop. (https://reactjs.org/link/special-props)', ); }); @@ -363,7 +363,7 @@ describe('ReactElement.jsx', () => { ReactDOM.render(JSXRuntime.jsx(Parent, {}), container), ).toErrorDev( 'Warning: Each child in a list should have a unique "key" prop.\n\n' + - 'Check the render method of `Parent`. See https://fb.me/react-warning-keys for more information.\n' + + 'Check the render method of `Parent`. See https://reactjs.org/link/warning-keys for more information.\n' + ' in Child (at **)\n' + ' in Parent (at **)', ); diff --git a/packages/react/src/__tests__/ReactElementValidator-test.internal.js b/packages/react/src/__tests__/ReactElementValidator-test.internal.js index c8209952c1cc3..ee5a3c66bc1e8 100644 --- a/packages/react/src/__tests__/ReactElementValidator-test.internal.js +++ b/packages/react/src/__tests__/ReactElementValidator-test.internal.js @@ -86,7 +86,7 @@ describe('ReactElementValidator', () => { ReactTestUtils.renderIntoDocument({divs}); }).toErrorDev( 'Warning: Each child in a list should have a unique ' + - '"key" prop. See https://fb.me/react-warning-keys for more information.\n' + + '"key" prop. See https://reactjs.org/link/warning-keys for more information.\n' + ' in div (at **)', ); }); @@ -99,7 +99,7 @@ describe('ReactElementValidator', () => { }).toErrorDev( 'Warning: Each child in a list should have a unique ' + '"key" prop.\n\nCheck the top-level render call using
. See ' + - 'https://fb.me/react-warning-keys for more information.\n' + + 'https://reactjs.org/link/warning-keys for more information.\n' + ' in div (at **)', ); }); @@ -120,7 +120,7 @@ describe('ReactElementValidator', () => { expect(() => ReactTestUtils.renderIntoDocument()).toErrorDev( 'Warning: Each child in a list should have a unique ' + '"key" prop.\n\nCheck the render method of `Component`. See ' + - 'https://fb.me/react-warning-keys for more information.\n' + + 'https://reactjs.org/link/warning-keys for more information.\n' + ' in div (at **)\n' + ' in Component (at **)\n' + ' in Parent (at **)\n' + diff --git a/packages/react/src/__tests__/ReactStrictMode-test.js b/packages/react/src/__tests__/ReactStrictMode-test.js index 055b71d8c7ff5..60862d12a9fe8 100644 --- a/packages/react/src/__tests__/ReactStrictMode-test.js +++ b/packages/react/src/__tests__/ReactStrictMode-test.js @@ -403,18 +403,18 @@ describe('Concurrent Mode', () => { expect(() => Scheduler.unstable_flushAll()).toErrorDev( [ /* eslint-disable max-len */ - `Warning: Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code. See https://fb.me/react-unsafe-component-lifecycles for details. + `Warning: Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code. See https://reactjs.org/link/unsafe-component-lifecycles for details. * Move code with side effects to componentDidMount, and set initial state in the constructor. Please update the following components: AsyncRoot`, - `Warning: Using UNSAFE_componentWillReceiveProps in strict mode is not recommended and may indicate bugs in your code. See https://fb.me/react-unsafe-component-lifecycles for details. + `Warning: Using UNSAFE_componentWillReceiveProps in strict mode is not recommended and may indicate bugs in your code. See https://reactjs.org/link/unsafe-component-lifecycles for details. * Move data fetching code or side effects to componentDidUpdate. -* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state +* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://reactjs.org/link/derived-state Please update the following components: Bar, Foo`, - `Warning: Using UNSAFE_componentWillUpdate in strict mode is not recommended and may indicate bugs in your code. See https://fb.me/react-unsafe-component-lifecycles for details. + `Warning: Using UNSAFE_componentWillUpdate in strict mode is not recommended and may indicate bugs in your code. See https://reactjs.org/link/unsafe-component-lifecycles for details. * Move data fetching code or side effects to componentDidUpdate. @@ -461,18 +461,18 @@ Please update the following components: AsyncRoot`, expect(() => Scheduler.unstable_flushAll()).toErrorDev( [ /* eslint-disable max-len */ - `Warning: Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code. See https://fb.me/react-unsafe-component-lifecycles for details. + `Warning: Using UNSAFE_componentWillMount in strict mode is not recommended and may indicate bugs in your code. See https://reactjs.org/link/unsafe-component-lifecycles for details. * Move code with side effects to componentDidMount, and set initial state in the constructor. Please update the following components: AsyncRoot`, - `Warning: Using UNSAFE_componentWillReceiveProps in strict mode is not recommended and may indicate bugs in your code. See https://fb.me/react-unsafe-component-lifecycles for details. + `Warning: Using UNSAFE_componentWillReceiveProps in strict mode is not recommended and may indicate bugs in your code. See https://reactjs.org/link/unsafe-component-lifecycles for details. * Move data fetching code or side effects to componentDidUpdate. -* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state +* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://reactjs.org/link/derived-state Please update the following components: Child`, - `Warning: Using UNSAFE_componentWillUpdate in strict mode is not recommended and may indicate bugs in your code. See https://fb.me/react-unsafe-component-lifecycles for details. + `Warning: Using UNSAFE_componentWillUpdate in strict mode is not recommended and may indicate bugs in your code. See https://reactjs.org/link/unsafe-component-lifecycles for details. * Move data fetching code or side effects to componentDidUpdate. @@ -484,20 +484,20 @@ Please update the following components: AsyncRoot`, }).toWarnDev( [ /* eslint-disable max-len */ - `Warning: componentWillMount has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details. + `Warning: componentWillMount has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details. * Move code with side effects to componentDidMount, and set initial state in the constructor. * Rename componentWillMount to UNSAFE_componentWillMount to suppress this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run \`npx react-codemod rename-unsafe-lifecycles\` in your project source folder. Please update the following components: Parent`, - `Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details. + `Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details. * Move data fetching code or side effects to componentDidUpdate. -* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state +* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://reactjs.org/link/derived-state * Rename componentWillReceiveProps to UNSAFE_componentWillReceiveProps to suppress this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run \`npx react-codemod rename-unsafe-lifecycles\` in your project source folder. Please update the following components: Parent`, - `Warning: componentWillUpdate has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details. + `Warning: componentWillUpdate has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details. * Move data fetching code or side effects to componentDidUpdate. * Rename componentWillUpdate to UNSAFE_componentWillUpdate to suppress this warning in non-strict mode. In React 18.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run \`npx react-codemod rename-unsafe-lifecycles\` in your project source folder. @@ -753,7 +753,7 @@ describe('string refs', () => { 'String refs are a source of potential bugs and should be avoided. ' + 'We recommend using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref\n' + + 'https://reactjs.org/link/strict-mode-string-ref\n' + ' in OuterComponent (at **)', ); @@ -794,7 +794,7 @@ describe('string refs', () => { 'String refs are a source of potential bugs and should be avoided. ' + 'We recommend using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref\n' + + 'https://reactjs.org/link/strict-mode-string-ref\n' + ' in InnerComponent (at **)\n' + ' in OuterComponent (at **)', ); @@ -874,7 +874,7 @@ describe('context legacy', () => { '\n\nPlease update the following components: ' + 'FunctionalLegacyContextConsumer, LegacyContextConsumer, LegacyContextProvider' + '\n\nLearn more about this warning here: ' + - 'https://fb.me/react-legacy-context' + + 'https://reactjs.org/link/legacy-context' + '\n in LegacyContextProvider (at **)' + '\n in div (at **)' + '\n in Root (at **)', diff --git a/packages/react/src/__tests__/createReactClassIntegration-test.js b/packages/react/src/__tests__/createReactClassIntegration-test.js index 8fec2209b9067..fc060fbf6ec90 100644 --- a/packages/react/src/__tests__/createReactClassIntegration-test.js +++ b/packages/react/src/__tests__/createReactClassIntegration-test.js @@ -555,7 +555,7 @@ describe('create-react-class-integration', () => { ' componentWillReceiveProps\n' + ' componentWillUpdate\n\n' + 'The above lifecycles should be removed. Learn more about this warning here:\n' + - 'https://fb.me/react-unsafe-component-lifecycles', + 'https://reactjs.org/link/unsafe-component-lifecycles', ); }).toWarnDev( [ @@ -598,7 +598,7 @@ describe('create-react-class-integration', () => { ' componentWillReceiveProps\n' + ' componentWillUpdate\n\n' + 'The above lifecycles should be removed. Learn more about this warning here:\n' + - 'https://fb.me/react-unsafe-component-lifecycles', + 'https://reactjs.org/link/unsafe-component-lifecycles', ); }).toWarnDev( [ diff --git a/packages/react/src/jsx/ReactJSXElement.js b/packages/react/src/jsx/ReactJSXElement.js index f76c92fb88bb4..c4c02c7418ab6 100644 --- a/packages/react/src/jsx/ReactJSXElement.js +++ b/packages/react/src/jsx/ReactJSXElement.js @@ -70,7 +70,7 @@ function warnIfStringRefCannotBeAutoConverted(config, self) { 'This case cannot be automatically converted to an arrow function. ' + 'We ask you to manually fix this case by using useRef() or createRef() instead. ' + 'Learn more about using refs safely here: ' + - 'https://fb.me/react-strict-mode-string-ref', + 'https://reactjs.org/link/strict-mode-string-ref', getComponentName(ReactCurrentOwner.current.type), config.ref, ); @@ -89,7 +89,7 @@ function defineKeyPropWarningGetter(props, displayName) { '%s: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + - 'prop. (https://fb.me/react-special-props)', + 'prop. (https://reactjs.org/link/special-props)', displayName, ); } @@ -111,7 +111,7 @@ function defineRefPropWarningGetter(props, displayName) { '%s: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + - 'prop. (https://fb.me/react-special-props)', + 'prop. (https://reactjs.org/link/special-props)', displayName, ); } diff --git a/packages/react/src/jsx/ReactJSXElementValidator.js b/packages/react/src/jsx/ReactJSXElementValidator.js index f7b6a779ea693..18a7cdd186299 100644 --- a/packages/react/src/jsx/ReactJSXElementValidator.js +++ b/packages/react/src/jsx/ReactJSXElementValidator.js @@ -162,7 +162,7 @@ function validateExplicitKey(element, parentType) { setCurrentlyValidatingElement(element); console.error( 'Each child in a list should have a unique "key" prop.' + - '%s%s See https://fb.me/react-warning-keys for more information.', + '%s%s See https://reactjs.org/link/warning-keys for more information.', currentComponentErrorInfo, childOwner, ); diff --git a/packages/scheduler/src/forks/SchedulerHostConfig.default.js b/packages/scheduler/src/forks/SchedulerHostConfig.default.js index 998380bd110a3..7df7b821c7416 100644 --- a/packages/scheduler/src/forks/SchedulerHostConfig.default.js +++ b/packages/scheduler/src/forks/SchedulerHostConfig.default.js @@ -91,7 +91,7 @@ if ( console['error']( "This browser doesn't support requestAnimationFrame. " + 'Make sure that you load a ' + - 'polyfill in older browsers. https://fb.me/react-polyfills', + 'polyfill in older browsers. https://reactjs.org/link/react-polyfills', ); } if (typeof cancelAnimationFrame !== 'function') { @@ -99,7 +99,7 @@ if ( console['error']( "This browser doesn't support cancelAnimationFrame. " + 'Make sure that you load a ' + - 'polyfill in older browsers. https://fb.me/react-polyfills', + 'polyfill in older browsers. https://reactjs.org/link/react-polyfills', ); } } diff --git a/packages/shared/invokeGuardedCallbackImpl.js b/packages/shared/invokeGuardedCallbackImpl.js index 60e32e0a55287..e7a1ba398a24e 100644 --- a/packages/shared/invokeGuardedCallbackImpl.js +++ b/packages/shared/invokeGuardedCallbackImpl.js @@ -215,7 +215,7 @@ if (__DEV__) { error = new Error( "A cross-origin error was thrown. React doesn't have access to " + 'the actual error object in development. ' + - 'See https://fb.me/react-crossorigin-error for more information.', + 'See https://reactjs.org/link/crossorigin-error for more information.', ); } this.onError(error); diff --git a/scripts/error-codes/codes.json b/scripts/error-codes/codes.json index 1cd9becd724f4..540655e24c608 100644 --- a/scripts/error-codes/codes.json +++ b/scripts/error-codes/codes.json @@ -60,7 +60,7 @@ "58": "dangerouslyReplaceNodeWithMarkup(...): Cannot replace markup of the node. This is because browser quirks make this unreliable and/or slow. If you want to render to the root you must use server rendering. See ReactDOMServer.renderToString().", "59": "%s is a void element tag and must not have `children` or use `props.dangerouslySetInnerHTML`.", "60": "Can only set one of `children` or `props.dangerouslySetInnerHTML`.", - "61": "`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://fb.me/react-invariant-dangerously-set-inner-html for more information.", + "61": "`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://reactjs.org/link/dangerously-set-inner-html for more information.", "62": "The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + 'em'}} when using JSX.", "63": "Must be mounted to trap events", "64": "trapBubbledEvent(...): Requires node to be rendered.", @@ -118,8 +118,8 @@ "116": "traverseParentPath(%s, %s, ...): Cannot traverse from two IDs that do not have a parent path.", "117": "traverseParentPath(%s, %s, ...): Detected an infinite loop while traversing the React DOM ID tree. This may be due to malformed IDs: %s", "118": "updateTextContent called on non-empty component.", - "119": "addComponentAsRefTo(...): Only a ReactOwner can have refs. You might be adding a ref to a component that was not created inside a component's `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).", - "120": "removeComponentAsRefFrom(...): Only a ReactOwner can have refs. You might be removing a ref to a component that was not created inside a component's `render` method, or you have multiple copies of React loaded (details: https://fb.me/react-refs-must-have-owner).", + "119": "addComponentAsRefTo(...): Only a ReactOwner can have refs. You might be adding a ref to a component that was not created inside a component's `render` method, or you have multiple copies of React loaded (details: https://reactjs.org/link/refs-must-have-owner).", + "120": "removeComponentAsRefFrom(...): Only a ReactOwner can have refs. You might be removing a ref to a component that was not created inside a component's `render` method, or you have multiple copies of React loaded (details: https://reactjs.org/link/refs-must-have-owner).", "121": "performUpdateIfNecessary: Unexpected batch number (current %s, pending %s)", "122": "%s(...): Expected the last optional `callback` argument to be a function. Instead received: %s.", "123": "ReactUpdates: must inject a reconcile transaction class and batching strategy", @@ -148,7 +148,7 @@ "146": "React Component in warnForMissingKey should have a _store. This error is likely caused by a bug in React. Please file an issue.", "147": "Missing owner for string ref %s. This error is likely caused by a bug in React. Please file an issue.", "148": "Expected ref to be a function or a string.", - "149": "Element ref was specified as a string (%s) but no owner was set. You may have multiple copies of React loaded. (details: https://fb.me/react-refs-must-have-owner).", + "149": "Element ref was specified as a string (%s) but no owner was set. You may have multiple copies of React loaded. (details: https://reactjs.org/link/refs-must-have-owner).", "150": "An object is not an iterable. This error is likely caused by a bug in React. Please file an issue.", "151": "An iterable object provided no iterator.", "152": "%s(...): Nothing was returned from render. This usually means a return statement is missing. Or, to render nothing, return null.", @@ -252,7 +252,7 @@ "251": "batch.commit: Cannot commit a batch multiple times.", "252": "The `document` global was defined when React was initialized, but is not defined anymore. This can happen in a test environment if a component schedules an update from an asynchronous callback, but the test has already finished running. To solve this, you can either unmount the component at the end of your test (and ensure that any asynchronous operations get canceled in `componentWillUnmount`), or you can change the test itself to be asynchronous.", "253": "work.commit(): Cannot commit while already rendering. This likely means you attempted to commit from inside a lifecycle method.", - "254": "Element ref was specified as a string (%s) but no owner was set. This could happen for one of the following reasons:\n1. You may be adding a ref to a functional component\n2. You may be adding a ref to a component that was not created inside a component's render method\n3. You have multiple copies of React loaded\nSee https://fb.me/react-refs-must-have-owner for more information.", + "254": "Element ref was specified as a string (%s) but no owner was set. This could happen for one of the following reasons:\n1. You may be adding a ref to a functional component\n2. You may be adding a ref to a component that was not created inside a component's render method\n3. You have multiple copies of React loaded\nSee https://reactjs.org/link/refs-must-have-owner for more information.", "255": "Expected ReactFbErrorUtils.invokeGuardedCallback to be a function.", "256": "Expected ReactFiberErrorDialog.showErrorDialog to be a function.", "257": "Portals are not currently supported by the server renderer. Render them conditionally so that they only appear on the client render.", @@ -274,7 +274,7 @@ "273": "Nesting of within is not currently supported.", "274": "Text strings must be rendered within a component.", "275": "The current renderer does not support mutation. This error is likely caused by a bug in React. Please file an issue.", - "276": "React depends on requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://fb.me/react-polyfills", + "276": "React depends on requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills", "277": "Context.unstable_read(): Context can only be read while React is rendering, e.g. inside the render method or getDerivedStateFromProps.", "278": "unstable_createRoot(...): Target container is not a DOM element.", "279": "Trying to release an event instance into a pool of a different type.", @@ -285,10 +285,10 @@ "284": "Expected ref to be a function, a string, an object returned by React.createRef(), or null.", "285": "The root failed to unmount after an error. This is likely a bug in React. Please file an issue.", "286": "%s(...): the first argument must be a React class instance. Instead received: %s.", - "287": "It is not supported to run the profiling version of a renderer (for example, `react-dom/profiling`) without also replacing the `schedule/tracking` module with `schedule/tracking-profiling`. Your bundler might have a setting for aliasing both modules. Learn more at http://fb.me/react-profiling", - "288": "It is not supported to run the profiling version of a renderer (for example, `react-dom/profiling`) without also replacing the `schedule/tracing` module with `schedule/tracing-profiling`. Your bundler might have a setting for aliasing both modules. Learn more at http://fb.me/react-profiling", + "287": "It is not supported to run the profiling version of a renderer (for example, `react-dom/profiling`) without also replacing the `schedule/tracking` module with `schedule/tracking-profiling`. Your bundler might have a setting for aliasing both modules. Learn more at https://reactjs.org/link/profiling", + "288": "It is not supported to run the profiling version of a renderer (for example, `react-dom/profiling`) without also replacing the `schedule/tracing` module with `schedule/tracing-profiling`. Your bundler might have a setting for aliasing both modules. Learn more at https://reactjs.org/link/profiling", "289": "Function components cannot have refs.", - "290": "Element ref was specified as a string (%s) but no owner was set. This could happen for one of the following reasons:\n1. You may be adding a ref to a function component\n2. You may be adding a ref to a component that was not created inside a component's render method\n3. You have multiple copies of React loaded\nSee https://fb.me/react-refs-must-have-owner for more information.", + "290": "Element ref was specified as a string (%s) but no owner was set. This could happen for one of the following reasons:\n1. You may be adding a ref to a function component\n2. You may be adding a ref to a component that was not created inside a component's render method\n3. You have multiple copies of React loaded\nSee https://reactjs.org/link/refs-must-have-owner for more information.", "291": "Log of yielded values is not empty. Call expect(Scheduler).toHaveYielded(...) first.", "292": "The matcher `toHaveYielded` expects an instance of React Test Renderer.\n\nTry: expect(Scheduler).toHaveYielded(expectedYields)", "293": "Context can only be read while React is rendering, e.g. inside the render method or getDerivedStateFromProps.", @@ -300,14 +300,14 @@ "299": "createRoot(...): Target container is not a DOM element.", "300": "Rendered fewer hooks than expected. This may be caused by an accidental early return statement.", "301": "Too many re-renders. React limits the number of renders to prevent an infinite loop.", - "302": "It is not supported to run the profiling version of a renderer (for example, `react-dom/profiling`) without also replacing the `scheduler/tracing` module with `scheduler/tracing-profiling`. Your bundler might have a setting for aliasing both modules. Learn more at http://fb.me/react-profiling", + "302": "It is not supported to run the profiling version of a renderer (for example, `react-dom/profiling`) without also replacing the `scheduler/tracing` module with `scheduler/tracing-profiling`. Your bundler might have a setting for aliasing both modules. Learn more at https://reactjs.org/link/profiling", "303": "ReactDOMServer did not find an internal fallback frame for Suspense. This is a bug in React. Please file an issue.", "304": "Maximum number of concurrent React renderers exceeded. This can happen if you are not properly destroying the Readable provided by React. Ensure that you call .destroy() on it if you no longer want to read from it, and did not read to the end. If you use .pipe() this should be automatic.", "305": "The current renderer does not support hydration. This error is likely caused by a bug in React. Please file an issue.", "306": "Element type is invalid. Received a promise that resolves to: %s. Lazy element type must resolve to a class or function.%s", - "307": "Hooks can only be called inside the body of a function component. (https://fb.me/react-invalid-hook-call)", + "307": "Hooks can only be called inside the body of a function component. (https://reactjs.org/link/invalid-hook-call)", "308": "Context can only be read while React is rendering. In classes, you can read it in the render method or getDerivedStateFromProps. In function components, you can read it directly in the function body, but not inside Hooks like useReducer() or useMemo().", - "309": "Function components cannot have string refs. We recommend using useRef() instead. Learn more about using refs safely here: https://fb.me/react-strict-mode-string-ref", + "309": "Function components cannot have string refs. We recommend using useRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref", "310": "Rendered more hooks than during the previous render.", "311": "Should have a queue. This is likely a bug in React. Please file an issue.", "312": "Rendered more hooks than during the previous render", @@ -319,7 +319,7 @@ "318": "A dehydrated suspense component was completed without a hydrated node. This is probably a bug in React.", "319": "A dehydrated suspense boundary must commit before trying to render. This is probably a bug in React.", "320": "Expected ReactFiberErrorDialog.showErrorDialog to be a function.", - "321": "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:\n1. You might have mismatching versions of React and the renderer (such as React DOM)\n2. You might be breaking the Rules of Hooks\n3. You might have more than one copy of React in the same app\nSee https://fb.me/react-invalid-hook-call for tips about how to debug and fix this problem.", + "321": "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:\n1. You might have mismatching versions of React and the renderer (such as React DOM)\n2. You might be breaking the Rules of Hooks\n3. You might have more than one copy of React in the same app\nSee https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.", "322": "forwardRef requires a render function but was given %s.", "323": "React has blocked a javascript: URL as a security precaution.", "326": "Expected a valid priority level",