From 110e62cd73975297fc09f3b09820bc18d4ac4356 Mon Sep 17 00:00:00 2001 From: TianenPang <32772271+TianenPang@users.noreply.github.com> Date: Thu, 31 Mar 2022 15:15:39 +0800 Subject: [PATCH 1/2] docs: update react 18 installation command, links and descriptions --- docs/advanced-features/react-18/overview.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/advanced-features/react-18/overview.md b/docs/advanced-features/react-18/overview.md index 735431c54d17ba6..83124c62fcdbf36 100644 --- a/docs/advanced-features/react-18/overview.md +++ b/docs/advanced-features/react-18/overview.md @@ -1,16 +1,16 @@ # React 18 -[React 18](https://reactjs.org/blog/2021/06/08/the-plan-for-react-18.html) adds new features including Suspense, automatic batching of updates, APIs like `startTransition`, and a new streaming API for server rendering with support for `React.lazy`. +[React 18](https://reactjs.org/blog/2022/03/29/react-v18.html) adds new features including Suspense, automatic batching of updates, APIs like `startTransition`, and a new streaming API for server rendering with support for `React.lazy`. Next.js also provides streaming related APIs, please checkout [next/streaming](/docs/api-reference/next/streaming.md) for details. -React 18 is now in Release Candidate (RC). Read more about React 18's [release plan](https://reactjs.org/blog/2021/06/08/the-plan-for-react-18.html) and discussions from the [working group](https://github.com/reactwg/react-18/discussions). +React 18 is now released. Read more about [React 18](https://reactjs.org/blog/2022/03/29/react-v18.html). ## Using React 18 with Next.js -Install the RC version of React 18: +Install the latest version of React: ```jsx -npm install next@latest react@rc react-dom@rc +npm install next@latest react@latest react-dom@latest ``` You can now start using React 18's new APIs like `startTransition` and `Suspense` in Next.js. From 089036430aeef8f53b1a3e7e5a436f43b4a87892 Mon Sep 17 00:00:00 2001 From: TianenPang <32772271+TianenPang@users.noreply.github.com> Date: Thu, 31 Mar 2022 15:38:56 +0800 Subject: [PATCH 2/2] docs: update react 18 installation command and description --- docs/advanced-features/react-18/server-components.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/advanced-features/react-18/server-components.md b/docs/advanced-features/react-18/server-components.md index be4cea72957c379..265dd4cb22e4723 100644 --- a/docs/advanced-features/react-18/server-components.md +++ b/docs/advanced-features/react-18/server-components.md @@ -4,10 +4,10 @@ Server Components allow us to render React components on the server. This is fun ### Enable React Server Components -To use React Server Components, ensure you have React 18 installed: +To use React Server Components, ensure you have the latest React installed: ```jsx -npm install next@canary react@rc react-dom@rc +npm install next@canary react@latest react-dom@latest ``` Then, update your `next.config.js`: