Unverified Commit 16e862ae authored by Tim Neutkens's avatar Tim Neutkens Committed by GitHub

docs: correct custom server optimization guidance (#94229)

## Summary

- remove the inaccurate claim that a custom server disables Automatic
Static Optimization
- retain the guidance to use a custom server only when the integrated
router cannot meet an app's requirements

## Verification

- `pnpm prettier --with-node-modules --ignore-path .prettierignore
--check docs/01-app/02-guides/custom-server.mdx`
- commit hook: `prettier --write` and `eslint --fix` for the changed MDX
file
parent 57ddbf81
...@@ -10,7 +10,7 @@ Next.js includes its own server with `next start` by default. If you have an exi ...@@ -10,7 +10,7 @@ Next.js includes its own server with `next start` by default. If you have an exi
> **Good to know**: > **Good to know**:
> >
> - Before deciding to use a custom server, keep in mind that it should only be used when the integrated router of Next.js can't meet your app requirements. A custom server will remove important performance optimizations, like **[Automatic Static Optimization](/docs/pages/building-your-application/rendering/automatic-static-optimization).** > - Before deciding to use a custom server, keep in mind that it should only be used when the integrated router of Next.js can't meet your app requirements.
> - When using standalone output mode, it does not trace custom server files. This mode outputs a separate minimal `server.js` file, instead. These cannot be used together. > - When using standalone output mode, it does not trace custom server files. This mode outputs a separate minimal `server.js` file, instead. These cannot be used together.
Take a look at the [following example](https://github.com/vercel/next.js/tree/canary/examples/custom-server) of a custom server: Take a look at the [following example](https://github.com/vercel/next.js/tree/canary/examples/custom-server) of a custom server:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment