\n\nThe schedule page has nested \"child\" routes, which are displayed as \"tabs\" using `\u003CNuxtChild />`.\n\n\u003Cimg width=\"1288\" height=\"664\" alt=\"Image\" src=\"https://github.com/user-attachments/assets/3f1a9bac-7094-4cd6-b5a8-3b6f8d26069f\" />\n\nWhen I visit the schedule route, I want to redirected to `schedule/[day].vue`, with \"day\" param set as \"1\", which would display the schedule for the first day of the event `/en/schedule/1`.\n\nI had to create a custom middleware because it was not supported.\n```js\n// schedule.vue\n\ndefinePageMeta({\n localeRedirect: {\n name: 'schedule-day',\n params: { day: 1 },\n },\n i18n: {\n paths: {\n fr: '/programmation',\n en: '/schedule',\n },\n },\n});\n```\n\n```js\n// localeRedirect.global.ts\n\nexport default defineNuxtRouteMiddleware((to) => {\n const localePath = useLocalePath();\n if (to.meta.localeRedirect && to.matched.length === 1 && !to.redirectedFrom) {\n return navigateTo(localePath(to.meta.localeRedirect));\n }\n});\n```\n\n### Additional information\n\n- [ ] Would you be willing to help implement this feature?\n- [ ] Could this feature be implemented as a module?\n\n### Final checks\n\n- [x] Read the [contribution guide](https://nuxt.com/docs/community/contribution) (The contribution guideline of nuxt-modules/i18n is compliant with Nuxt too).\n- [x] Check existing [discussions](https://github.com/nuxt-modules/i18n/discussions) and [issues](https://github.com/nuxt/nuxt/issues).",[3194],{"name":3173,"color":3174},3801,"Add i18n support to `redirect` inside `definePageMeta`","2025-08-31T09:50:36Z","https://github.com/nuxt-modules/i18n/issues/3801",0.73725396,{"description":3201,"labels":3202,"number":3204,"owner":3176,"repository":3177,"state":3178,"title":3205,"updated_at":3206,"url":3207,"score":3208},"### Environment\n\n- Node Version: v23.11.0\n- Nuxt Version: 3.17.5\n- Nitro Version: 2.11.12\n- @nuxtjs/i18n: 9.5.5\n- Package Manager: pnpm@9.5.0\n\n### Reproduction\n\nhttps://stackblitz.com/edit/bobbiegoede-nuxt-i18n-starter-5cgp8cfo?file=package.json,components%2FLangSwitcher.vue,pages%2Findex.vue,pages%2Fnews%2Findex.vue,pages%2Fnews%2F[slug]%2Findex.vue,nuxt.config.ts\n\n### Describe the bug\n\nWhen using a simple language switcher like this:\n\n```vue\n\u003Ctemplate>\n \u003Cdiv class=\"lang-switch\">\n \u003CNuxtLink\n v-for=\"availableLocale in availableLocales\"\n :key=\"availableLocale.code\"\n :to=\"switchLocalePath(availableLocale.code)\"\n >\n {{ availableLocale.name }}\n \u003C/NuxtLink>\n \u003C/div>\n\u003C/template>\n\n\u003Cscript setup>\nconst { locale, locales } = useI18n();\nconst switchLocalePath = useSwitchLocalePath();\nconst availableLocales = computed(() => {\n return locales.value.filter((i) => i.code !== locale.value);\n});\n\u003C/script>\n```\n\nIf you are on a dynamic route (e.g. `/news/[slug]`), navigating to another page causes Vue Router to warn:\n\n```\n[Vue Router warn]: Discarded invalid param(s) \"slug\" when navigating. See https://github.com/vuejs/router/blob/main/packages/router/CHANGELOG.md#414-2022-08-22 for more details.\n```\n\n## Expected behavior\nNo warning should be emitted when navigating, even from dynamic routes.\n\n## Actual behavior\nA warning is emitted every time the user navigates from a dynamic route to another page.\n\n### Additional context\n\n_No response_\n\n### Logs\n\n```shell\n[Vue Router warn]: Discarded invalid param(s) \"slug\" when navigating. \nSee https://github.com/vuejs/router/blob/main/packages/router/CHANGELOG.md#414-2022-08-22 for more details.\nlocalePathFor\t@\tindex.vue?t=1750772396716:31\n(anonymous)\t@\tindex.vue?t=1750772396716:51\n_sfc_render\t@\tindex.vue?t=1750772396716:48\n```",[3203],{"name":3173,"color":3174},3702,"Language switcher with switchLocalePath causes [Vue Router warn]: Discarded invalid param(s) \"slug\" on dynamic routes","2025-06-24T14:14:55Z","https://github.com/nuxt-modules/i18n/issues/3702",0.7380231,{"description":3210,"labels":3211,"number":3213,"owner":3176,"repository":3177,"state":3178,"title":3214,"updated_at":3215,"url":3216,"score":3217},"### Environment\n\n- Operating System: Darwin\n- Node Version: v22.15.0\n- Nuxt Version: 3.17.3\n- CLI Version: 3.25.1\n- Nitro Version: 2.11.12\n- Package Manager: npm@10.9.2\n- Builder: -\n- User Config: compatibilityDate, devtools, modules, i18n, nitro\n- Runtime Modules: @nuxt/content@3.5.1, @nuxtjs/i18n@9.5.4\n- Build Modules: -\n\n\n### Reproduction\n\nA minimal reproduction of this issue can be found in the following repository: https://github.com/odan-sandbox/nuxt-content-and-i18n-no_prefix-example\n\n\n### Describe the bug\n\nWhen using the `no_prefix` strategy in `nuxt-i18n`, the locale detection based on the URL pathname is not functioning as expected. This results in incorrect locale assignment during SSR/SSG.\n\nFor example, accessing `/en/about` and `/ja/about` should render the corresponding locale-specific content, but instead, both paths are rendered using the default or server locale, ignoring the locale information in the pathname.\n\nThis issue causes problems for multilingual documentation sites using `nuxt/content`, where the content is structured by locale (e.g., `docs/en/about.md`, `docs/ja/about.md`). During SSG, both paths may be generated with the same language content, leading to incorrect output.\n\nIf a PR to resolve this issue is considered appropriate, I would be willing to work on it.\n\n\n### Additional context\n\nRelated: https://github.com/nuxt-modules/i18n/issues/3609\n\n### Logs\n\n```shell\n\n```",[3212],{"name":3173,"color":3174},3619,"Locale detection not working with `no_prefix` strategy","2025-05-19T06:13:27Z","https://github.com/nuxt-modules/i18n/issues/3619",0.74602294,{"description":3219,"labels":3220,"number":3224,"owner":3176,"repository":3177,"state":3225,"title":3226,"updated_at":3227,"url":3228,"score":3229},"### Environment\r\n\r\n------------------------------\r\n- Operating System: Linux\r\n- Node Version: v18.16.0\r\n- Nuxt Version: 3.7.1\r\n- CLI Version: 3.7.3\r\n- Nitro Version: 2.6.2\r\n- Package Manager: pnpm@8.6.12\r\n- Builder: -\r\n- User Config: extends, telemetry, ssr, fontMetrics, nitro, routeRules, runtimeConfig, build, modules, delayHydration, image, components, bugsnag, devtools, i18n, experimental, pwa, app, dnGraphqlClient, vite, plugins\r\n- Runtime Modules: @nuxtjs/fontaine@0.4.1, @pinia/nuxt@0.4.11, @nuxt/devtools@0.8.2, @vite-pwa/nuxt@0.1.0, nuxt-bugsnag@7.0.0, @digitalnatives/css-variables/nuxt@5.1.3, @digitalnatives/graphql-client@4.0.3, @nuxtjs/i18n@8.0.0-rc.4, @nuxt/image@1.0.0-rc.1, nuxt-delay-hydration@1.2.1, @digitalnatives/composables@2.0.1\r\n- Build Modules: -\r\n------------------------------\r\n\r\n### Reproduction\r\n\r\nA naïve reproduction is the following:\r\n\r\n```js\r\nconst route = useRoute(); \r\nconst locale = useLocale();\r\n\r\n// On switch, this will first log the NEW locale with the OLD path, then it will trigger a second time, logging the NEW locale with the NEW path\r\nwatchEffect(() => {\r\n console.log(route.fullPath);\r\n console.log(locale);\r\n});\r\n```\r\n\r\nAdd it to a global component in the layout that doesn't get mounted/umounted on URI change.\r\n\r\n\r\n\r\n### Describe the bug\r\n\r\nWhen using prefixed routes and a language switcher as described in the docs, it seems the locale changes before the route does.\r\n\r\nWhen watching the locale with `useAsyncData()` or `useLazyAsyncData()` this will cause the results of this call to be associated with the wrong URL/path, which then has a side-effect of refetching API data which was already pre-rendered in Nuxt static mode. Therefore, the pre-rendered payload is NOT used in this pattern, even though it should.\r\n\r\nI've also seen this lead to data mismatching to the wrong paths, but this is a bit harder to create a reproduction for.\r\n\r\n### Additional context\r\n\r\nMy current workaround is this;\r\n\r\ncomposable:\r\n```js\r\nexport const useVariables = () => {\r\n const route = useRoute();\r\n const { $i18n }: any = useNuxtApp();\r\n // Don't automatically update the site and url to ensure they both change at the same time\r\n variables.uri = toValue(route.path);\r\n variables.lang = toValue($i18n?.localeProperties)?.apiLanguageHandle;\r\n\r\n // Update variables manually when the route changes, at this point both the locale AND the URI are correct.\r\n watch(() => route.path, () => {\r\n variables.uri = toValue(route.path);\r\n variables.lang = toValue($i18n?.localeProperties)?.apiLanguageHandle;\r\n });\r\n return { variables };\r\n});\r\n```\r\n\r\nthen:\r\n\r\n```js\r\nconst { variables } = useVariables();\r\nuseAsyncData(() => { console.log('trigger!') } , { watch: [ variables ] });\r\n```\r\n\r\n\r\nPerhaps it would be possible to inject the locale & locale properties into the localized route meta? That way we could just watch the route and apply the language from that.\r\n\r\nRelates to #2278 \r\n\r\n### Logs\r\n\r\n_No response_",[3221],{"name":3222,"color":3223},"switch locale","D2FCC6",2377,"closed","`locale` changes BEFORE the route path does, which causes issues with (static) `asyncData`-payloads","2025-05-16T11:44:11Z","https://github.com/nuxt-modules/i18n/issues/2377",0.69988585,{"description":3231,"labels":3232,"number":3234,"owner":3176,"repository":3177,"state":3225,"title":3235,"updated_at":3236,"url":3237,"score":3238},"### Environment\n\n------------------------------\n- Operating System: Linux\n- Node Version: v20.19.1\n- Nuxt Version: 4.0.0\n- CLI Version: 3.26.3\n- Nitro Version: 2.12.0\n- Package Manager: pnpm@8.15.6\n- Builder: -\n- User Config: modules, devtools, i18n\n- Runtime Modules: @nuxtjs/i18n@10.0.1\n- Build Modules: -\n------------------------------\n\n### Reproduction\n\nhttps://stackblitz.com/edit/bobbiegoede-nuxt-i18n-starter-zx2czsy7?file=nuxt.config.ts\n\n### Describe the bug\n\nWhen employing the prefix strategy, navigating to a page without a locale prefix (e.g., localhost:3000/test-page instead of localhost:3000/en/test-page) results in an HTTP 404 (Not Found) error. While the client-side URL subsequently updates to include the correct prefix, the server fails to issue a redirect.\n\nThe server should respond with a redirect to the prefixed URL, similar to how it handles redirects for the root path.\n\n### Additional context\n\n_No response_\n\n### Logs\n\n```shell\n\n```",[3233],{"name":3173,"color":3174},3741,"Redirect to fallback local missing paths other then the root path","2025-07-21T08:40:29Z","https://github.com/nuxt-modules/i18n/issues/3741",0.7094408,{"description":3240,"labels":3241,"number":3243,"owner":3176,"repository":3177,"state":3225,"title":3244,"updated_at":3245,"url":3246,"score":3247},"### Environment\n\n- Operating System: `Darwin`\n- Node Version: `v22.14.0`\n- Nuxt Version: `4.0.3`\n- CLI Version: `3.28.0`\n- Nitro Version: `2.12.4`\n- Package Manager: `pnpm@9.15.3`\n- Builder: `-`\n- User Config: `compatibilityDate`, `devtools`, `modules`, `i18n`\n- Runtime Modules: `@nuxtjs/i18n@10.0.6`\n- Build Modules: `-`\n\n\n### Reproduction\n\nhttps://stackblitz.com/edit/github-bxz4vuj6?file=nuxt.config.ts,package.json,app%2Fapp.vue\n\n### Describe the bug\n\nI'm not sure if I'm doing something wrong, but following the example for a lang switcher in the docs: https://i18n.nuxtjs.org/docs/guide/different-domains\n\nresults in `\u003Ca>` tags without an actual `href` because the `switchLocalePath` function returns an empty string.\n\n\u003Cimg width=\"222\" height=\"48\" alt=\"Image\" src=\"https://github.com/user-attachments/assets/21c2ff37-fd75-4b34-a944-e7d050a5edcd\" />\n\n### Additional context\n\n_No response_\n\n### Logs\n\n```shell\n\n```",[3242],{"name":3173,"color":3174},3792,"`switchLocalePath` returns an empty string","2025-08-21T22:49:06Z","https://github.com/nuxt-modules/i18n/issues/3792",0.7162793,{"description":3249,"labels":3250,"number":3257,"owner":3176,"repository":3177,"state":3225,"title":3258,"updated_at":3259,"url":3260,"score":3261},"### Environment\n\n- Operating System: `Darwin`\n- Node Version: `v22.15.0`\n- Nuxt Version: `3.17.4`\n- CLI Version: `3.25.1`\n- Nitro Version: `2.11.12`\n- Package Manager: `npm@10.9.2`\n- Builder: `-`\n- User Config: `devtools`, `modules`, `i18n`, `compatibilityDate`, `app`\n- Runtime Modules: `@nuxtjs/i18n@9.5.4`\n- Build Modules: `-`\n\n\n### Reproduction\n\nhttps://github.com/cjpearson/switch-locale-path-repro\n\n### Describe the bug\n\nWhen using different domains for each locale, `switchLocalePath` will return an absolute URL for the current route in a different locale. However, if `app.baseURL` will not be included if it is set.\n\nFor example, calling `switchLocalePath` on `http://en.localhost/prefix/testing` will return `http://nl.localhost/testing`.\n\nThis is also the case when using path prefixes instead of domains, but less of an issue in practice since NuxtLink automatically adds the baseURL.\n\n### Additional context\n\n_No response_\n\n### Logs\n\n```shell\n\n```",[3251,3254],{"name":3252,"color":3253},"bug 🐛","ee0701",{"name":3255,"color":3256},"domain","fbca04",3628,"`switchLocalePath` should include the baseURL","2025-05-22T15:50:22Z","https://github.com/nuxt-modules/i18n/issues/3628",0.7177212,{"description":3263,"labels":3264,"number":3271,"owner":3176,"repository":3177,"state":3225,"title":3272,"updated_at":3273,"url":3274,"score":3275},"### Environment\r\n\r\n------------------------------\r\n- Operating System: Darwin\r\n- Node Version: v20.11.0\r\n- Nuxt Version: 3.10.1\r\n- CLI Version: 3.10.0\r\n- Nitro Version: 2.8.1\r\n- Package Manager: yarn@4.0.1\r\n- Builder: -\r\n- User Config: modules, i18n, devtools\r\n- Runtime Modules: @nuxtjs/i18n@8.1.0\r\n- Build Modules: -\r\n------------------------------\r\n\r\n\r\n### Reproduction\r\n\r\nhttps://stackblitz.com/edit/github-c7te5q-rzxba2\r\n\r\n### Describe the bug\r\n\r\n`useLocaleHead` doesn't work with `useSetI18nParams` because `\u003Clink rel=\"alternate\" />` aren't sync. \r\n\r\n### Additional context\r\n\r\nif i go from Homepage `/it` to the blog page `/it/blog-1-ita` using the **Go at Blog Page** button, the alternate links don't change; but i've set all the i18nParams\r\n```js\r\nsetI18nParams({\r\n it: { blog: 'blog-1-it' },\r\n de: { blog: 'blog-1-de' },\r\n en: false,\r\n})\r\n```\r\n\r\nIf i refresh the page when i'm in the blog page, the `\u003Clink rel=\"alternate\" />` are duplicated (and also `canonical`).\r\n```html\r\n\u003Clink rel=\"alternate\" href=\"https://www.dummy.com/en/blog-1-ita\" hreflang=\"en\" data-hid=\"7fcee50\">\r\n\u003Clink rel=\"alternate\" href=\"https://www.dummy.com/it/blog-1-ita\" hreflang=\"it\" data-hid=\"08fce45\">\r\n\u003Clink rel=\"alternate\" href=\"https://www.dummy.com/de/blog-1-ita\" hreflang=\"de\" data-hid=\"5d718b2\">\r\n\u003Clink rel=\"alternate\" href=\"https://www.dummy.com/it/blog-1-ita\" hreflang=\"x-default\" data-hid=\"6527e7a\">\r\n\u003Clink rel=\"canonical\" href=\"https://www.dummy.com/it/blog-1-ita\" data-hid=\"5cca6f5\">\r\n\r\n\u003Clink id=\"i18n-alt-it\" rel=\"alternate\" href=\"https://www.dummy.com/it/blog-1-it\" hreflang=\"it\">\r\n\u003Clink id=\"i18n-alt-de\" rel=\"alternate\" href=\"https://www.dummy.com/de/blog-1-de\" hreflang=\"de\">\r\n\u003Clink id=\"i18n-xd\" rel=\"alternate\" href=\"https://www.dummy.com/it/blog-1-it\" hreflang=\"x-default\">\r\n\u003Clink id=\"i18n-can\" rel=\"canonical\" href=\"https://www.dummy.com/it/blog-1-ita\">\r\n```\r\n\r\n### Logs\r\n\r\n_No response_",[3265,3268],{"name":3266,"color":3267},"🍰 p2-nice-to-have","0e8a16",{"name":3269,"color":3270},"scope: seo","30CDE0",2779,"`useSetI18nParams` and `useLocaleHead` `rel=\"alternate\"` aren't sync. ","2025-07-20T20:12:38Z","https://github.com/nuxt-modules/i18n/issues/2779",0.7206219,["Reactive",3277],{},["Set"],["ShallowReactive",3280],{"$fTRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"$fU9taZpurZ1snCimBPmjXnx_Bw8qnEupxDlyw9_a5uEs":-1},"/nuxt-modules/i18n/3405"]