App Router
Next.js 13.4, released on May 4, 2023, marked the App Router as stable and ready for production use. v14 added Server Actions
Updating versions
Routing
/pages
=>/app
[..slug].ts => [...slug]/page.ts
Client-side rendering ⇒ Server Components by default, need
use client
to changeLayouts in
_app.ts
=>layout.ts
an allows nested layouts(just include in folder)getStaticProps
,getServerSideProps
,getInitialProps
⇒ Async server components can just call fetchCustom pages like
404.js
,500.js
⇒error.js
andglobal-error.js
for route segments and global errorsneed to update image tags, not much benefit
metadata tags=> export metadata
Last updated