-
-
Notifications
You must be signed in to change notification settings - Fork 519
Open
Labels
Description
Describe the feature
I can see that despite having a few configuration options, the module is opinionated in terms of path preference. In case of the prefix_and_default strategy, it consistently prefers a path with no prefix. I don't think this should be the case: the module users should have an option to change this, depending on what drew them to thinking about using this strategy.
I would like to have an option to set the opposite preference, so that specifically:
- When
setLocaleis called, the user is redirected to/en/foorather than/foo. - Each corresponding
linkofrel="alternate"(for the language), as well as that ofrel="canonical", points to/en/foo. - The default
linkofrel="alternate"(hreflang="x-default") points to/foo.
IMHO this behavior would even make for a nice default for this strategy and it would play nice with SEO if one ever chose to switch between prefix_and_default and prefix (with redirectOn: 'no prefix') at some point, while these two strategies are the best ones for SEO and caching.
Additional information
- Would you be willing to help implement this feature?
- Could this feature be implemented as a module?
Final checks
- Read the contribution guide (The contribution guideline of nuxt-modules/i18n is compliant with Nuxt too).
- Check existing discussions and issues.
Reactions are currently unavailable