From c5fef7a845e6d2d765867f3b0a51b11deb8c8d7b Mon Sep 17 00:00:00 2001 From: huyikai Date: Fri, 12 Apr 2024 09:22:13 +0800 Subject: [PATCH] i18n(zh-cn): Create `missing-middelware-for-internationalization.mdx` --- .../missing-middleware-for-internationalization.mdx | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 src/content/docs/zh-cn/reference/errors/missing-middleware-for-internationalization.mdx diff --git a/src/content/docs/zh-cn/reference/errors/missing-middleware-for-internationalization.mdx b/src/content/docs/zh-cn/reference/errors/missing-middleware-for-internationalization.mdx new file mode 100644 index 0000000000000..d0aac45794964 --- /dev/null +++ b/src/content/docs/zh-cn/reference/errors/missing-middleware-for-internationalization.mdx @@ -0,0 +1,13 @@ +--- +title: 启用了手动国际化路由但没有提供中间件。 +i18nReady: true +githubURL: https://github.com/withastro/astro/blob/main/packages/astro/src/core/errors/errors-data.ts +--- + +> **MissingMiddlewareForInternationalization**: 你的配置设置 `i18n.routing: 'manual'` 要求你提供自己的 i18n `middleware` 文件。 + +## 哪里出了问题? +如果用户启用了手动路由,但没有中间件文件,Astro 会抛出一个错误。 + + +