Commit Graph

1072 Commits

Author SHA1 Message Date
Jiwon Choi bbfcbe9611 Rename MiddlewareMatcher to ProxyMatcher (#85005)
Follow up on https://github.com/vercel/next.js/pull/84710, `adapterPath`
docs had `MiddlewareMatcher` type, used in `ProxyConfig` type. As it's a
user-facing type, update it.
2025-10-17 23:29:53 +02:00
Janka Uryga bae8bf4606 [Cache Components] fix docs for cacheLife("seconds") (#85004)
Looks like this was missed in #82332, when we bumped the staletime to
30s.
2025-10-17 23:09:58 +02:00
Jiwon Choi bc59f210b0 docs: Deprecation of Middleware (#84710)
This PR removes middleware docs and adds a "Migration to Proxy" section
to the Proxy docs, which explains the rationale for the renaming to
Proxy and provides a migration guide.

Did not remove `middleware-upgrade-docs` as it's an upgrade doc from the
legacy middleware.

Below are untouched as they need codebase changes:

- `instrumentation` docs - `onRequestError` has `context.routeType` as
`'middleware'`
- `adapterPath` docs - has `MiddlewareMatcher` type example
- `ProxyConfig` - has a user-facing `MiddlewareMatcher` type

---------

Co-authored-by: Joseph Chamochumbi <joseph.chamochumbi@vercel.com>
2025-10-17 20:03:13 +02:00
Jiwon Choi 71ce95dffa docs: Replace Middleware docs to Proxy (#84709)
> [!NOTE]
> Best reviewed by each commit for better diff view.

This PR clones the Middleware docs for Proxy and removes the Middleware docs.

Did not clone the list of docs:

- `errors/middleware-upgrade.mdx` - It's a middleware upgrade guide from v12.2
- `errors/beta-middleware.mdx` - It's an error when using middleware before v12.2
- `errors/returning-response-body.mdx` - Legacy behavior from versions < v12.2
2025-10-17 16:13:26 +02:00
Jiwon Choi fd8b4c5979 docs: Split "Get Started: Route Handlers and Middleware" to Route Handlers and Proxy (#84708)
This PR splits the route handlers and middleware to allow for separate
onboarding docs, making it easier to migrate the docs from Middleware to
Proxy.

These PR stacks are to publish a full replacement of the docs for the
Middleware to Proxy. Steps are as follows:

- Split "Get Started: Route Handlers and middleware" to Route Handlers /
Proxy
- Clone the Middleware docs for Proxy
- Add "Migration to Proxy" section to Middleware docs
  - Explain the rationale for the renaming to Proxy
  - Provide migration guide
- Add an error doc that the deprecation warning can refer to. The error
doc will:
  - Explain why this error occurred
  - Provide migration guide
  - Explain the rationale for the renaming to Proxy
2025-10-17 16:00:14 +02:00
Joseph 332aaf3939 docs: getting started installation and next lint removal (#84781)
- [x] verify rendering of the changes

Also addressing: #84772

---------

Co-authored-by: Jiwon Choi <devjiwonchoi@gmail.com>
2025-10-17 15:39:21 +02:00
Muhammad Rohan Hussain 7296aa624e Update prefetching.mdx providing more clarity on the usage of router.prefetch() (#84903)
## What
Updated `prefetching.mdx` in the App Router documentation providing more
clarity on the usage of `router.prefetch()`.

## Why
We found the current section on `Manual Prefetching` to be lacking in
detail and a bit misleading as well.

The issue with the current version of the documentation is that the code
snippet provided:
```tsx
const router = useRouter();
router.prefetch();
```
Makes it seem like `router.prefetch()` can be called at the same level
as `useRouter()`, i.e. in the component body, even though that causes
the page to crash for many possible reasons, such as `window is not
defined`, or `Router action dispatched before initialization.`.

I am not sure if this is helpful/correct or not, just thought this may
help someone. If not feel free to close this PR. Thanks in advance for
your time.

## Reproduction
Here is a codesandbox reproducing the issue that occurs if you follow
the code snippet trivially:
https://codesandbox.io/p/devbox/s5pmsj

<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation

- Run `pnpm prettier-fix` to fix formatting issues before opening the
PR. (Done)
- Read the Docs Contribution Guide to ensure your contribution follows
the docs guidelines:
https://nextjs.org/docs/community/contribution-guide (Done)


Closes NEXT-
Fixes #

-->

---------

Co-authored-by: Joseph <joseph.chamochumbi@vercel.com>
2025-10-17 15:20:22 +02:00
Jiwon Choi 8bc8dc343c docs: Add missing codemod docs (#84980)
- middleware-to-proxy
- remove-unstable-prefix
2025-10-17 13:20:17 +02:00
Jiwon Choi b42555aa39 Add codemod for removing experimental_ppr (#84979)
`experimental_ppr` is removed by
https://github.com/vercel/next.js/pull/84871, so add codemod for it.
2025-10-17 03:45:02 +02:00
Joseph 828211efa1 docs: Templates on navigation (#84493)
The docs on Template and its life cycle, were not that clear.

Closes:
https://linear.app/vercel/issue/DOC-5107/review-templates-api-reference

---------

Co-authored-by: Ismael <ismael@vercel.com>
2025-10-17 00:45:30 +02:00
Joseph 45fcbdea7a docs: x-nextjs-stale-time header (#84901)
Let's add a note about this header.

-
https://github.com/vercel/next.js/blob/3ae7ace09338bcde92ececb6b03a03760f302aed/packages/next/src/server/app-render/app-render.tsx#L2076-L2079

-
https://github.com/vercel/next.js/blob/3ae7ace09338bcde92ececb6b03a03760f302aed/packages/next/src/client/components/segment-cache-impl/cache.ts#L262-L268

-
https://github.com/vercel/next.js/blob/3ae7ace09338bcde92ececb6b03a03760f302aed/packages/next/src/client/components/segment-cache-impl/cache.ts#L318-L326

---------

Co-authored-by: Ismael <ismael@vercel.com>
2025-10-17 00:45:09 +02:00
Joseph c2863c8724 Docs/sync with new features 0 (#84861)
Sync w/ isolatedDevBuild and updateTag+revalidatePath/Tag

---------

Co-authored-by: Rich Haines <hello@richardhaines.dev>
2025-10-16 19:31:24 +00:00
Zack Tanner 014228f097 stabilize experimental.enablePrerenderSourcemaps (#84916)
As part of stabilizing cacheComponents, we are also stabilizing
supporting flags. This flag has been enabled with cacheComponents for
some time and so we are moving it out of experimental.

It will continue to be enabled by default if you are using
cacheComponents. Otherwise, it can be opted into independently via next
config.

Closes https://linear.app/vercel/issue/NDX-1048
Closes https://github.com/vercel/next.js/pull/80317

---------

Co-authored-by: Sebastian "Sebbie" Silbermann <sebastian.silbermann@vercel.com>
2025-10-16 11:37:01 -07:00
Josh Story 76d2beaeb8 [Cache Components] Remove unstable prefix from unstable_cacheTag (#84880)
`cacheLife` is now stable and does not require an unstable prefix
2025-10-16 07:01:44 -07:00
Josh Story 8cab15c0c9 [Cache Components] Remove unstable prefix from unstable_cacheLife (#84877)
`cacheLife` is now stable and does not require an unstable prefix
2025-10-15 08:14:04 -07:00
Joseph 3ae7ace093 docs: next/dynamic headings (#84492)
Reworking and re-organizing the next/dynamic section - headings were not
consistent for Pages Router. The Pages router section also talked about
client and server components.
2025-10-15 14:09:20 +02:00
Luke Sandberg 17c99ca4e5 [turbopack] fix typo in docs (#84868)
https://github.com/vercel/next.js/pull/84837 merged a bit too quickly
2025-10-14 10:45:46 -07:00
Luke Sandberg 81b35a698c [turbopack] document missing webpack loader features (#84849)
This has come up a bit so we could attempt to be clear about it.
2025-10-14 10:24:53 -07:00
Luke Sandberg e36e29e3a7 [turbopack] Discuss Core Web vitals in our bundle size gap docs (#84837)
Core Web Vitals are generally a superior approach to web app perf, so we should mention them
2025-10-14 10:22:20 -07:00
Joseph cd524f57ec docs: soft 404's, Suspense and loading.tsx (#83867)
Closes: https://linear.app/vercel/issue/DOC-5089/soft-404s-in-the-docs

---------

Co-authored-by: Zack Tanner <1939140+ztanner@users.noreply.github.com>
2025-10-14 12:36:55 +02:00
Luke Sandberg 37f4c793c9 [turbopack] Fix a few references to caching configuration as it is no longer canary guarded (#84761) 2025-10-10 12:46:14 -07:00
Luke Sandberg ee15207961 [turbopack] tweak the doc on the inner graph optimization (#84752)
This optimization is enabled by default and we already link to the docs so referencing the configuration option is more misleading than helpful.

Fixes https://github.com/vercel/feedback/issues/111264
2025-10-10 09:52:35 -07:00
Joseph a89f854f3e Revert "docs: nav_title for long unbroken words (#84233)" (#84346)
The pattern we use in other `config` metadata is to use the `config`
name.
2025-10-10 07:56:23 -07:00
Benjamin Woodruff 8f731e666f docs: Add more details to useLightningcss docs (#84581)
Adds a bit more context about the current state of the world.

Adds a warning if you set this to anything other than `undefined` on Turbopack:

![Screenshot 2025-10-09 at 4.18.02 PM.png](https://app.graphite.dev/user-attachments/assets/fbe4c8f5-6b1f-466c-953c-b16ae2f33751.png)
2025-10-09 18:48:46 -07:00
Zack Tanner b2ce9dd9c3 tweak middlewareClientMaxBodySize handling (#84712)
This ensures we captured `middlewareClientMaxBodySize` in the config
schema and rather than triggering a hard error, it will buffer up to the
limit.
2025-10-09 17:10:41 -07:00
Wyatt Johnson 3630146458 Add validation for missing default.js in parallel routes (#84702)
### What?

Adds build-time validation to require explicit `default.js` files for
all parallel route slots (except the implicit "children" slot). This
validation is implemented in both Webpack and Turbopack bundlers.

### Why?

Parallel routes without `default.js` files currently cause silent 404
errors when users navigate to those routes. This creates confusion and
hard-to-debug issues because the routes appear to be configured
correctly but fail at runtime without any indication of what went wrong.

By making this validation explicit at build time, developers get
immediate feedback about missing required files with clear error
messages and documentation links, catching configuration mistakes before
deployment.

### How?

**Rust/Turbopack** (`crates/next-core/src/app_structure.rs`): Added
`MissingDefaultParallelRouteIssue` that emits a build error when a
parallel route slot is missing its `default.js` file. The validation is
skipped for the "children" slot since it's implicit and doesn't require
a default file.

**Webpack**
(`packages/next/src/build/webpack/loaders/next-app-loader/index.ts`):
Added validation that throws `MissingDefaultParallelRouteError` when
`default.js` cannot be resolved. The "children" slot falls back to the
existing `PARALLEL_ROUTE_DEFAULT_PATH` behavior for backward
compatibility.

**Error Class**
(`packages/next/src/shared/lib/errors/missing-default-parallel-route-error.ts`):
New error type with helpful messaging that includes the slot path,
explanation of the requirement, and a link to documentation.

**Migration Path**: Users who want the previous 404 behavior can
explicitly create a `default.js` that calls `notFound()`, or return
`null` for empty slots:

```tsx
import { notFound } from 'next/navigation'

export default function Default() {
  notFound()
}
```

Users can also run the following Deno script to generate the default
files for them:
https://gist.github.com/wyattjoh/ba7263ecb637ef399d3e3e4db63ffbd6

**Breaking Change**: This is a breaking change timed for Next.js 16
beta. Builds will now fail if parallel route slots are missing required
`default.js` files.
2025-10-09 15:20:52 -06:00
JJ Kasper e598a4f976 Add new updateTag API and new signature for revalidateTag (#83822) 2025-10-09 14:03:01 -07:00
Steven 8d415853f7 [Breaking] feat(next/image)!: add support for images.dangerouslyAllowLocalIP and images.maximumRedirects (#84676)
This PR adds a two new options and sets a strict default value for each.

- `images.dangerouslyAllowLocalIP`
- `images.maximumRedirects`

### dangerouslyAllowLocalIP

In rare cases when self-hosting Next.js on a private network, you may
want to allow optimizing images from local IP addresses on the same
network.

However, this is not recommended for most users so the default is
`false`.

> [!NOTE]
> BREAKING CHANGE: This change is breaking for those who self-hosting
Next.js on a private network and want to allow optimizing images from
local IP addresses on the same network. In those cases, you can still
enable the config.

### maximumRedirects

Since are also testing redirects for local IPs, we can also reduce the
maximum number of redirects to 3 by default.

Unlike normal websites which might redirect for features like auth, its
unusual to have more than 3 redirects for an image.

In some rare cases, developers may need to increase this value or set to
`0` to disable redirects.

> [!NOTE]
> BREAKING CHANGE: This change is breaking for those who need image
optimization to follow more than 3 redirects.
2025-10-09 22:00:53 +02:00
Jiwon Choi 8041a382c9 [Breaking] Require images.localPatterns for query in Image src (#84406)
This PR modifies Image behavior to require `images.localPatterns.search`
value when used with search queries in the `src` property:

```jsx
// Error
<Image src="/api/user?id=1" width="50" height="50" />
```

```ts
// next.config.ts

export default {
  images: {
    localPatterns: [
      {
        pathname: '/api/user',
        // Either set explicit query string or leave undefined to match all
        search: '?v=2',
      },
    ],
  },
}
```

It is to prevent malicious actors like Denial of Wallet (DoW) attacks
and strictly match the search queries for image optimization.

The deprecation warning was added at
https://github.com/vercel/next.js/pull/82627

---------

Co-authored-by: Steven <steven@ceriously.com>
2025-10-09 21:01:42 +02:00
Zack Tanner 5dcfec401a Add refresh API to next/cache (#84666)
This provides a way to refresh the client cache from within a server
action. This is useful when you need to refresh the client UI / read
your writes without needing to rely on `updateTag`.

---------

Co-authored-by: JJ Kasper <jj@jjsweb.site>
2025-10-09 11:47:51 -07:00
Karl Horky 0b14eb2ed2 Add note about $ACTION_ properties, remove reference to .entries() (#84459)
<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation

- Run `pnpm prettier-fix` to fix formatting issues before opening the
PR.
- Read the Docs Contribution Guide to ensure your contribution follows
the docs guidelines:
https://nextjs.org/docs/community/contribution-guide

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs)
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md


## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->

### What?

Make a note about the `$ACTION_` properties in `formData`

### Why?

Starting with next@14.1.3, `$ACTION_` properties have appeared in the
`formData`, which cause validation errors when used with a strict
validation with a library such as Zod or Yup:

```tsx
// Form Client Component
export default function Form() {
  const [state, formAction] = useFormState(action, {
    type: 'initial',
  });

  return (
    <form action={action}>
      {/* ... */}
    </form>
  );
}

// Server Action
export async function action(
  prevState: ServerActionReturnValue,
  formData: FormData,
): Promise<ServerActionReturnValue> {
  const validationResult = await schema.validate(
    Object.fromEntries(formData.entries()),
  );
```

The errors from Yup:

Errors:

- this field has unspecified keys: $ACTION_REF_1, $ACTION_1:0,
$ACTION_1:1, $ACTION_KEY
The data in the formData.entries()

```js
{
  '$ACTION_REF_1': '',
  '$ACTION_1:0': '{"id":"59f475b...","bound":"$@1"}',
  '$ACTION_1:1': '[{"type":"initial"}]',
  '$ACTION_KEY': 'k187677481',
  // Real form data starts here:
  year: '2024',
```

### How?

1. Document additional properties with keys starting with the prefix
`$ACTION_`
2. Remove the obsolete mention of `.entries()`, since that is not being
used in the code example anymore (previously, it was `const rawFormData
= Object.fromEntries(formData.entries())`)

### History

- The `$ACTION_` property change was added in
https://github.com/vercel/next.js/pull/63048
- The `docs/01-app/02-guides/forms.mdx` file was added in PR
https://github.com/vercel/next.js/pull/79288 , without the `$ACTION_`
property change

cc @delbaoliveira

Co-authored-by: Joseph <joseph.chamochumbi@vercel.com>
2025-10-09 10:29:50 -07:00
brock-statsig 954d40be14 add Statsig Node Core package to Server External Packages (#84157)
### What?
Statsig is a popular AB Testing/ Feature Flagging solution to use in concert with Next.js. Today, their newest Server SDK doesn't play nicely with Next as its build around a Rust library, which doesn't play nice with webpack and causes build issues.

### Why?
This'll remove a step for Statsig/Next developers having to troubleshoot and add @statsig/statsig-node-core to serverExternalPackages themselves.

### How?
Added to the list published here: https://nextjs.org/docs/app/api-reference/config/next-config-js/serverExternalPackages
2025-10-09 14:55:05 +02:00
Steven 600238f0b6 breaking(next/image)!: remove 16px from default images.imageSizes config (#84647)
We took a look at unique Next.js projects that have one or more requests
for a specific image size and here are the findings as seen from the
Image Optimization API:

- `w=16` 4.2%
- `w=32` 17.1%
- `w=48` 21.4%
- `w=64` 22.6%
- `w=96` 25.8%
- `w=128` 29.5%
- `w=256` 46.5%
- `w=384` 35.1%
- `w=640` 57.2%

Only 4.2% of Next.js projects ever made a request to a 16px width image.
This is low enough to remove from the default configuration so that all
other projects can benefit from reduced html
[srcset](https://developer.mozilla.org/en-US/docs/Web/API/HTMLImageElement/srcset)
and fewer variations exposed from the backend API.

You might think that this means few developers are using `<Image
width={16} />` but it probably means that most displays nowadays use
devicePixelRatio 2 meaning that specifying a 16px image width will
actually fetch the 32px width to ensure it won't looking blurry on your
retina display.

BREAKING CHANGE: this is technically a breaking change but it won't
cause apps to stop working, its just 4% of them may have some requests
serve a 32px image instead of 16px. Those apps can of course opt in by
changing their `images.imageSizes` config back to allowing 16.
2025-10-09 14:31:58 +02:00
Ben Gubler 41e39426eb Remove automatic linting from build (#83136)
### What?
This PR removes the automatic ESLint linting that previously ran during `next build`. The documentation has been updated to reflect this change.

### Why?
As part of Next.js 16, we're removing the automatic build-time linting that was previously included in the build process. This gives developers more control over when linting runs by explicitly invoking their linter via npm scripts.

### How?
- Updated documentation to clarify that automatic build-time linting has been removed in Next.js 16
- Removed the `runLint` parameter and related linting code from the build process
- Removed the `verifyAndLint.ts` file which is no longer needed
- Simplified type checking code by removing lint-related functionality
- Removed ESLint telemetry during builds
2025-10-08 16:35:07 -07:00
Gavin Kline 112ef61103 docs: add note clarifying project root in monorepo (#84628)
### What?
- Adding a small note to clarify the meaning of the phrase "project
root" in the documentation for next.config output, specifically in
regards to a monorepo setup

### Why?
- While doing some debugging related to a container that I cannot build
locally for compliance reasons, I had to take shots in the dark to
figure this behavior out 😄 hoping it can help the next soul who finds
themselves in a similar predicament

### How?
- Explain that in monorepos, "project root" does not mean the root of
the monorepo, but instead the root of the nextjs app



First time contributing, so I appreciate any reviews/feedback I can get
here, even for such a small PR. Thanks!

---------

Co-authored-by: Joseph <joseph.chamochumbi@vercel.com>
Co-authored-by: Joseph <sephxd1234@gmail.com>
2025-10-08 16:29:31 -07:00
Jiwon Choi 4f19d01c52 docs: experimental.isolatedDevBuild (#84656)
This doc is mainly to provide the users with information on how to opt
out of this feature. We could later remove these docs and the option
when the need to opt out is low.

---------

Co-authored-by: Joseph Chamochumbi <joseph.chamochumbi@vercel.com>
2025-10-09 01:22:19 +02:00
Luke Sandberg ad17ea67c2 docs: update core documentation for Turbopack as default bundler (#84282)
Update next.js docs to account for turbopack being the default bundler.
2025-10-08 14:22:56 -07:00
Jiachi Liu c08e05f5c7 [docs] update other params type of metadata image routes (#84491)
Co-authored-by: Joseph Chamochumbi <joseph.chamochumbi@vercel.com>
2025-10-08 13:56:50 -07:00
Jiwon Choi ab09e87861 Reapply "[Breaking] Remove deprecated publicRuntimeConfig and serverRuntimeConfig (#83944)" (#84167) (#84637)
In addition to reapplying #83944, removed added tests and warnings from
https://github.com/vercel/next.js/pull/84168
2025-10-08 21:41:04 +02:00
Tobias Koppers f90a780d3e Turbopack: rename turbopackPersistentCachingForXXX to turbopackFileSystemCacheForXXX (#84632)
### What?

Improve naming of the feature: `Turbopack FileSystem Cache`
2025-10-08 16:32:05 +02:00
Steven 364db96f05 feat(next/image)!: deprecate and warn on images.domains config (#84625)
This was docs deprecated in Next.js 14 so we should begin warning in
Next.js 16 when `images.domains` config is used.

This will guide users to providing a strict `images.remotePatterns`
config ensuring only expected images can be optimized.
2025-10-07 23:21:36 -04:00
JJ Kasper 9c9e793bdc Add middleware to routes order doc (#84618)
This adds `middleware` in the routes order to clarify where it comes in
priority.
2025-10-07 14:58:07 -07:00
nextjs-bot adb2829e4c Upgrade React from c7862584-20251006 to a4eb2dfa-20251006 (#84589)
Co-authored-by: Sebastian Sebbie Silbermann <sebastian.silbermann@vercel.com>
2025-10-07 07:01:50 -07:00
JJ Kasper c0a7c84256 Add documentation for experimental adapters handling (#83737)
This adds initial documentation for the new adapter interface initially
outlined in this RFC https://github.com/vercel/next.js/discussions/77740

---------

Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Co-authored-by: Zack Tanner <1939140+ztanner@users.noreply.github.com>
2025-10-07 04:44:38 +00:00
Joseph 7f25da71fb docs: simplify streaming metadata (#84253)
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
2025-10-03 17:16:39 +02:00
João Henrique ce56f8aa91 fix: Missing link in Lazy Loading docs (#84473)
Add missing space before "Importing Client Components" in Lazy Loading
/app docs.

This fixes the missing link in "On this page" sidebar:

<img width="1092" height="446" alt="image"
src="https://github.com/user-attachments/assets/0981467d-ad61-494d-80b2-c0a0e323dd0b"
/>

In the current state, the first link is "Skipping SSR" (second link)
instead of "Importing Client Components"

Co-authored-by: Joseph <joseph.chamochumbi@vercel.com>
2025-10-03 15:59:01 +02:00
Brian Lou c781f40bd1 Add gt-next to i18n list (#84396) 2025-10-02 14:15:05 -07:00
Sireesha Aguru b000436453 Docs/project structure polish (#84386)
PR title - docs: polish Project Structure page (grammar, consistency,
clarity)
PR description -
1) Fixes an Oxford comma in the routing files description for
consistency.
2) Normalizes heading capitalization to sentence case. 
3) Corrects “Files conventions” → “File conventions”. 
4) Aligns not-found.js description with earlier table (it’s not an error
boundary). Clarifies intercepting routes microcopy.

<!-- Thanks for opening a PR! Your contribution is much appreciated.
To make sure your PR is handled as smoothly as possible we request that
you follow the checklist sections below.
Choose the right checklist for the change(s) that you're making:

## For Contributors

### Improving Documentation

- Run `pnpm prettier-fix` to fix formatting issues before opening the
PR.
- Read the Docs Contribution Guide to ensure your contribution follows
the docs guidelines:
https://nextjs.org/docs/community/contribution-guide

### Fixing a bug

- Related issues linked using `fixes #number`
- Tests added. See:
https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md

### Adding a feature

- Implements an existing feature request or RFC. Make sure the feature
request has been accepted for implementation before opening a PR. (A
discussion must be opened, see
https://github.com/vercel/next.js/discussions/new?category=ideas)
- Related issues/discussions are linked using `fixes #number`
- e2e tests added
(https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs)
- Documentation added
- Telemetry added. In case of a feature if it's used or not.
- Errors have a helpful link attached, see
https://github.com/vercel/next.js/blob/canary/contributing.md


## For Maintainers

- Minimal description (aim for explaining to someone not on the team to
understand the PR)
- When linking to a Slack thread, you might want to share details of the
conclusion
- Link both the Linear (Fixes NEXT-xxx) and the GitHub issues
- Add review comments if necessary to explain to the reviewer the logic
behind a change

### What?

### Why?

### How?

Closes NEXT-
Fixes #

-->

---------

Co-authored-by: Joseph <joseph.chamochumbi@vercel.com>
2025-10-01 21:28:20 +02:00
Jiwon Choi a4b96c81db [Breaking] Bump minimum TypeScript version to 5.1.0 (#84384)
This PR bumps the minimum TS version required for Next.js to `5.1.0`,
which is the version that supports React Components that return a
promise via `JSX.ElementType`.


https://devblogs.microsoft.com/typescript/announcing-typescript-5-1/#decoupled-type-checking-between-jsx-elements-and-jsx-tag-types

---------

Co-authored-by: Sebastian "Sebbie" Silbermann <silbermann.sebastian@gmail.com>
2025-10-01 15:05:10 +02:00
Luke Sandberg 4adf73c64f Remove references to size metrics in next build from our docs (#83823)
Update docs to account for the removal of JS size metrics.  See #83815 for full context
2025-09-30 09:01:19 -07:00