Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

getValidLangKey erroneously assumes some paths to be specific languages #130

Open
alexej-d opened this issue Jun 30, 2020 · 0 comments
Open

Comments

@alexej-d
Copy link

Take for example a configuration, were the languages en and de are defined and for pages with the en language there should be no lang code in the url:
{ resolve: 'gatsby-plugin-i18n', options: { prefixDefault: false, langKeyDefault: 'en', useLangKeyLayout: false, } }

In this case getValidLangKey wouldn't correctly work with urls like /destinations because those are assumed to be languages (the language de in this case). Setting prefixDefault to true would fix this, but makes it impossible to use a default language without the lang code url path.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant