@@ -801,7 +801,7 @@ describe('ReactComponentLifeCycle', () => { |
801 | 801 | ' UNSAFE_componentWillReceiveProps\n' + |
802 | 802 | ' componentWillUpdate\n\n' + |
803 | 803 | 'The above lifecycles should be removed. Learn more about this warning here:\n' + |
804 | | - 'https://fb.me/react-unsafe-component-lifecycles', |
| 804 | + 'https://reactjs.org/link/unsafe-component-lifecycles', |
805 | 805 | ); |
806 | 806 | }).toWarnDev( |
807 | 807 | [ |
@@ -827,7 +827,7 @@ describe('ReactComponentLifeCycle', () => { |
827 | 827 | 'WillMount uses getDerivedStateFromProps() but also contains the following legacy lifecycles:\n' + |
828 | 828 | ' UNSAFE_componentWillMount\n\n' + |
829 | 829 | 'The above lifecycles should be removed. Learn more about this warning here:\n' + |
830 | | - 'https://fb.me/react-unsafe-component-lifecycles', |
| 830 | + 'https://reactjs.org/link/unsafe-component-lifecycles', |
831 | 831 | ); |
832 | 832 |
|
833 | 833 | class WillMountAndUpdate extends React.Component { |
@@ -851,7 +851,7 @@ describe('ReactComponentLifeCycle', () => { |
851 | 851 | ' componentWillMount\n' + |
852 | 852 | ' UNSAFE_componentWillUpdate\n\n' + |
853 | 853 | 'The above lifecycles should be removed. Learn more about this warning here:\n' + |
854 | | - 'https://fb.me/react-unsafe-component-lifecycles', |
| 854 | + 'https://reactjs.org/link/unsafe-component-lifecycles', |
855 | 855 | ); |
856 | 856 | }).toWarnDev(['componentWillMount has been renamed'], { |
857 | 857 | withoutStack: true, |
@@ -874,7 +874,7 @@ describe('ReactComponentLifeCycle', () => { |
874 | 874 | 'WillReceiveProps uses getDerivedStateFromProps() but also contains the following legacy lifecycles:\n' + |
875 | 875 | ' componentWillReceiveProps\n\n' + |
876 | 876 | 'The above lifecycles should be removed. Learn more about this warning here:\n' + |
877 | | - 'https://fb.me/react-unsafe-component-lifecycles', |
| 877 | + 'https://reactjs.org/link/unsafe-component-lifecycles', |
878 | 878 | ); |
879 | 879 | }).toWarnDev(['componentWillReceiveProps has been renamed'], { |
880 | 880 | withoutStack: true, |
@@ -906,7 +906,7 @@ describe('ReactComponentLifeCycle', () => { |
906 | 906 | ' UNSAFE_componentWillReceiveProps\n' + |
907 | 907 | ' componentWillUpdate\n\n' + |
908 | 908 | 'The above lifecycles should be removed. Learn more about this warning here:\n' + |
909 | | - 'https://fb.me/react-unsafe-component-lifecycles', |
| 909 | + 'https://reactjs.org/link/unsafe-component-lifecycles', |
910 | 910 | ); |
911 | 911 | }).toWarnDev( |
912 | 912 | [ |
@@ -931,7 +931,7 @@ describe('ReactComponentLifeCycle', () => { |
931 | 931 | 'WillMount uses getSnapshotBeforeUpdate() but also contains the following legacy lifecycles:\n' + |
932 | 932 | ' UNSAFE_componentWillMount\n\n' + |
933 | 933 | 'The above lifecycles should be removed. Learn more about this warning here:\n' + |
934 | | - 'https://fb.me/react-unsafe-component-lifecycles', |
| 934 | + 'https://reactjs.org/link/unsafe-component-lifecycles', |
935 | 935 | ); |
936 | 936 |
|
937 | 937 | class WillMountAndUpdate extends React.Component { |
@@ -954,7 +954,7 @@ describe('ReactComponentLifeCycle', () => { |
954 | 954 | ' componentWillMount\n' + |
955 | 955 | ' UNSAFE_componentWillUpdate\n\n' + |
956 | 956 | 'The above lifecycles should be removed. Learn more about this warning here:\n' + |
957 | | - 'https://fb.me/react-unsafe-component-lifecycles', |
| 957 | + 'https://reactjs.org/link/unsafe-component-lifecycles', |
958 | 958 | ); |
959 | 959 | }).toWarnDev(['componentWillMount has been renamed'], { |
960 | 960 | withoutStack: true, |
@@ -976,7 +976,7 @@ describe('ReactComponentLifeCycle', () => { |
976 | 976 | 'WillReceiveProps uses getSnapshotBeforeUpdate() but also contains the following legacy lifecycles:\n' + |
977 | 977 | ' componentWillReceiveProps\n\n' + |
978 | 978 | 'The above lifecycles should be removed. Learn more about this warning here:\n' + |
979 | | - 'https://fb.me/react-unsafe-component-lifecycles', |
| 979 | + 'https://reactjs.org/link/unsafe-component-lifecycles', |
980 | 980 | ); |
981 | 981 | }).toWarnDev(['componentWillReceiveProps has been renamed'], { |
982 | 982 | withoutStack: true, |
@@ -1383,20 +1383,20 @@ describe('ReactComponentLifeCycle', () => { |
1383 | 1383 | expect(() => ReactDOM.render(<MyComponent x={1} />, container)).toWarnDev( |
1384 | 1384 | [ |
1385 | 1385 | /* eslint-disable max-len */ |
1386 | | - `Warning: componentWillMount has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details. |
| 1386 | + `Warning: componentWillMount has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details. |
1387 | 1387 |
|
1388 | 1388 | * Move code with side effects to componentDidMount, and set initial state in the constructor. |
1389 | 1389 | * 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. |
1390 | 1390 |
|
1391 | 1391 | Please update the following components: MyComponent`, |
1392 | | - `Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details. |
| 1392 | + `Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details. |
1393 | 1393 |
|
1394 | 1394 | * Move data fetching code or side effects to componentDidUpdate. |
1395 | | -* 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 |
| 1395 | +* 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 |
1396 | 1396 | * 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. |
1397 | 1397 |
|
1398 | 1398 | Please update the following components: MyComponent`, |
1399 | | - `Warning: componentWillUpdate has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details. |
| 1399 | + `Warning: componentWillUpdate has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details. |
1400 | 1400 |
|
1401 | 1401 | * Move data fetching code or side effects to componentDidUpdate. |
1402 | 1402 | * 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. |
|