From 60dbe682010840c33d2bd68a254f9905c9af0956 Mon Sep 17 00:00:00 2001 From: moss-bryophyta <261561981+moss-bryophyta@users.noreply.github.com> Date: Wed, 3 Jun 2026 08:02:52 -0700 Subject: [PATCH] fix: add callout types and bold lead in middleware guide - Add type="info" to file location and example callouts - Add type="warn" and bold lead "**Caution:**" to matcher warning callout --- docs/en-US/next/guides/middleware.mdx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/en-US/next/guides/middleware.mdx b/docs/en-US/next/guides/middleware.mdx index cd000d55..7d17f801 100644 --- a/docs/en-US/next/guides/middleware.mdx +++ b/docs/en-US/next/guides/middleware.mdx @@ -6,7 +6,7 @@ description: Automatic language detection and URL routing based on user preferen Middleware automatically detects user language preferences and redirects them to the appropriate localized version of your site. It uses browser settings, geolocation, and user preferences to serve the right language before any content loads. - + **File location:** Place `proxy.ts` in your project root, at the same level as your `app/` directory - not inside it. `proxy.ts` (Next.js 16+) or `middleware.ts` (Next.js 15 and below) @@ -134,13 +134,13 @@ export const config = { }; ``` - - Test your middleware configuration thoroughly - incorrect matchers can cause infinite redirects or break static assets. + + **Caution:** Test your middleware configuration thoroughly — incorrect matchers can cause infinite redirects or break static assets. ## Next steps - + **See it in action:** The [static site generation example app](https://github.com/gt-examples/static-site-generation) includes a full middleware setup with locale routing — [live preview](https://static-site-generation.generaltranslation.dev).