React 18 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 for details.
React 18 is now released. Read more about React 18.
Install the latest version of React:
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.
Streaming server-rendering (SSR) is an experimental feature in Next.js 12. When enabled, SSR will use the same Edge Runtime as Middleware.
Learn how to enable streaming in Next.js.
Server Components are a new feature in React that let you reduce your JavaScript bundle size by separating server and client-side code. Server Components allow developers to build apps that span the server and client, combining the rich interactivity of client-side apps with the improved performance of traditional server rendering.
Server Components are still in research and development. Learn how to try Server Components as an experimental feature in Next.js.