Environment
Operating System: Darwin
- Node Version: v22.12.0
- Nuxt Version: 4.0.3
- CLI Version: 3.28.0
- Nitro Version: 2.12.5-20250819-230311.89278001
- Package Manager: [email protected]
-@nuxtjs/i18n version: 10.2.1
Reproduction
<NuxtLinkLocale to="/about" custom v-slot="{ isActive, navigate }">
<button @click="navigate" >
About us
</button>
</NuxtLinkLocale>
Describe the bug
NuxtLinkLocale wraps NuxtLink but does not preserve the generic on NuxtLinkProps.
Because of this, passing :custom="true" produces a TypeScript error:
Type 'true' is not assignable to type 'false'.
Additional context
A simple fix would be to preserve the generic or use boolean:
type NuxtLinkLocaleProps = Omit<NuxtLinkProps<boolean>, 'to'> & { //added <boolean>
to?: RouteLocationNamedI18n
locale?: Locale
}
Logs