@@ -52,7 +52,6 @@ export function proxy(request: NextRequest) {
...
@@ -52,7 +52,6 @@ export function proxy(request: NextRequest) {
// Alternatively, you can use a default export:
// Alternatively, you can use a default export:
// export default function proxy(request: NextRequest) { ... }
// export default function proxy(request: NextRequest) { ... }
// See "Matching Paths" below to learn more
export const config = {
export const config = {
matcher: '/about/:path*',
matcher: '/about/:path*',
}
}
...
@@ -69,10 +68,11 @@ export function proxy(request) {
...
@@ -69,10 +68,11 @@ export function proxy(request) {
// Alternatively, you can use a default export:
// Alternatively, you can use a default export:
// export default function proxy(request) { ... }
// export default function proxy(request) { ... }
// See "Matching Paths" below to learn more
export const config = {
export const config = {
matcher: '/about/:path*',
matcher: '/about/:path*',
}
}
```
```
The `matcher` config allows you to filter Proxy to run on specific paths. See the [Matcher](/docs/app/api-reference/file-conventions/proxy#matcher) documentation for more details on path matching.
Read more about [using `proxy`](/docs/app/guides/backend-for-frontend#proxy), or refer to the `proxy` [API reference](/docs/app/api-reference/file-conventions/proxy).
Read more about [using `proxy`](/docs/app/guides/backend-for-frontend#proxy), or refer to the `proxy` [API reference](/docs/app/api-reference/file-conventions/proxy).
@@ -195,7 +195,7 @@ Provide params ahead of time to prerender pages at build time. You can prerender
...
@@ -195,7 +195,7 @@ Provide params ahead of time to prerender pages at build time. You can prerender
During the build process, the route is executed with each sample param to collect the HTML result. If dynamic content or runtime data are accessed incorrectly, the build will fail.
During the build process, the route is executed with each sample param to collect the HTML result. If dynamic content or runtime data are accessed incorrectly, the build will fail.