rsnext/docs/api-reference/next.config.js
Javi Velasco f354f46b3f
Deprecate nested Middleware in favor of root middleware (#36772)
This PR deprecates declaring a middleware under `pages` in favour of the project root naming it after `middleware` instead of `_middleware`. This is in the context of having a simpler execution model for middleware and also ships some refactor work. There is a ton of a code to be simplified after this deprecation but I think it is best to do it progressively.

With this PR, when in development, we will **fail** whenever we find a nested middleware but we do **not** include it in the compiler so if the project is using it, it will no longer work. For production we will **fail** too so it will not be possible to build and deploy a deprecated middleware. The error points to a page that should also be reviewed as part of **documentation**.

Aside from the deprecation, this migrates all middleware tests to work with a single middleware. It also splits tests into multiple folders to make them easier to isolate and work with. Finally it ships some small code refactor and simplifications.
2022-05-19 15:46:21 +00:00
..
basepath.md Clarify rewrites and other docs cleanup. (#24890) 2021-05-07 13:09:15 +00:00
build-indicator.md Add config support for build activity indicator position (#30109) 2021-11-03 21:17:36 +00:00
cdn-support-with-asset-prefix.md Refactor data fetching API docs (#30615) 2022-01-12 08:56:51 +01:00
compression.md Remove outdated documentation (#20714) 2021-01-04 10:45:57 +01:00
configuring-onDemandEntries.md [docs] Added related links to next.config.js (#10174) 2020-01-20 21:40:20 +01:00
configuring-the-build-id.md fix(docs): Fix typo in Custom Build Id docs (#33515) 2022-01-21 04:12:53 +00:00
custom-page-extensions.md Deprecate nested Middleware in favor of root middleware (#36772) 2022-05-19 15:46:21 +00:00
custom-webpack-config.md docs: add more details about nextRuntime in webpack config and runtime in next config (#36862) 2022-05-12 16:53:59 +00:00
disabling-etag-generation.md [docs] Added related links to next.config.js (#10174) 2020-01-20 21:40:20 +01:00
disabling-http-keep-alive.md Add next.config.js option to override default keepAlive (#27709) 2021-08-03 00:38:42 +00:00
disabling-x-powered-by.md x-powered-by is added to response, not request (#13037) 2020-05-18 12:58:29 -04:00
environment-variables.md Remove reference to now env example (#17341) 2020-09-24 18:30:39 +00:00
exportPathMap.md Fixed duplicate data fetching overview page + links (#33774) 2022-01-29 02:52:40 +00:00
headers.md Update details about Cache Control Headers (#34416) 2022-02-17 23:17:26 +00:00
ignoring-eslint.md [ESLint] Documentation updates + bug fixes (#26331) 2021-08-05 00:58:06 +00:00
ignoring-typescript-errors.md Improve TypeScript documentation. (#34690) 2022-02-28 08:32:27 +00:00
introduction.md Fix introduction.md for next.config.js (#36286) 2022-04-19 20:35:49 +00:00
react-strict-mode.md Improve React Strict Mode documentation. (#28139) 2021-08-15 17:44:00 +00:00
redirects.md Added note about why Next.js used 307 and 308 status codes (#35325) 2022-03-19 16:49:24 +00:00
rewrites.md Fix typo in rewrites docs (#35639) 2022-03-27 18:15:08 +00:00
runtime-configuration.md Update runtime-configuration.md (#36923) 2022-05-16 09:15:01 +00:00
setting-a-custom-build-directory.md [docs] Added related links to next.config.js (#10174) 2020-01-20 21:40:20 +01:00
static-optimization-indicator.md Bring back indicator documentation with a note that the feature has been removed 2021-01-05 12:47:52 +01:00
trailing-slash.md Clarify rewrites and other docs cleanup. (#24890) 2021-05-07 13:09:15 +00:00
url-imports.md Fix heading levels in URL imports docs. (#31163) 2021-11-08 17:51:05 +00:00