intl sub path routing redirects defaultLanguage to path without lang subpath #67061
Replies: 1 comment
-
hmm, ok I found that I basically have to have [defaultLanguage, secondlangversionofdefault, otherlang] and then host/en still works. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Summary
I assume actually this is working as intended, and the documentation is just somewhat unclear - so for example if I have the following configuration
module.exports = {
i18n: {
locales: ['en', 'fr'],
defaultLocale: 'en',
},
}
then I would expect routes like this https://host/en would serve the root path / of the site, but what happens is a redirect to https://host which is not what I wanted to happen and not what I expected - of course https://host/fr is working as expected (serves / with locale settings)
Is there a way to to make that every en route then stays /en and does not redirect and can that be set in the configuration dynamically, that is to say can I have one site do the redirection and another one serve /en without redirecting?
I also get hydration errors, as I understand that is to be expected and I should suppress the warning or I am way off base on this issue?
Additional information
No response
Example
No response
Beta Was this translation helpful? Give feedback.
All reactions