To make our router compatible with streaming, and to solve these requests for enhanced support for layouts, we set out to build a new version of our router. Page transitions, data fetching, caching, mutating and revalidating data, streaming, styling content, and more. This wasn't an easy thing to retrofit into the existing Next.js router.Įvery part of the framework has to be designed around the router. But as usage of the framework grew, so have the types of interfaces developers are looking to build with it.ĭevelopers have asked for improved support for defining layouts, nesting pieces of UI as layouts, and having more flexibility over defining loading and error states. We still love this simplicity with routing. Drop a file inside pages/ and the Next.js router would take care of the rest. There was nothing additional to configure. In our original post, we showed this example of creating a route from a single React component: // Pages Router // pages/about.js import React from 'react' export default ( ) => About us Use the filesystem as an APIįile-system based routing has been a core feature of Next.js. This post will share more about our design decisions and choices for the App Router. We've been working on the next generation of Next.js, and today with 13.4, this next generation is stable and ready for adoption. Our original design principles have remained-and as Next.js has been adopted by more developers and companies, we have been working on a foundational upgrade to the framework to better achieve these principles. Automatic server rendering and code splitting.In the original announcement post, we shared some design principles of Next.js: ![]() We released Next.js in 2016 to provide an easy way to server-render React applications, with our goal to create a more dynamic, personalized, and global web. Today, with the release of 13.4, you can now start adopting the App Router for production. Since the release of Next.js 13 six months ago, we've been focused on building the foundations for the future of Next.js-App Router-in a way that can be incrementally adopted without unnecessary breaking changes. Server Actions (Alpha): Mutate data on the server with zero client JavaScript.Turbopack (Beta): Your local dev server, faster and with improved stability.Next.js 13.4 is a foundational release, marking stability for the App Router:
0 Comments
Leave a Reply. |