This repository was archived by the owner on May 10, 2021. It is now read-only.
[i18n] non-default locales in sub-path-routing lacking redirects #108
Labels
duplicate
This issue or pull request already exists
I came across a bug, where automatic redirects based on a non-default locale result in an HTTP status 404.
While the project builds just fine, it seems the
i18n
routes are not properly redirected using the_redirects
file. They all end up in an HTTP status 404. The i18n-configuration innext.config.js
is the following:[en, de]
en
The outcome after
next build
:You see, there are a lot of
getServerSideProps
server-side rendered routes (mainly due to SEO information in<head>
). The generated_redirects
file bynext-on-netlify
is the following:So to have a proper route catching, the following redirects are missing IMO:
For SSG routes, it seems there is no 'fallback' redirect to the resulting default locale sub-path (e.g.
/about
➡️/en/about.html
)What I've already tried
Manually adding the mentioned
/de
&/en
redirects above, but in case for/de
, they end up in endless redirects. So I'm assuming there's some work needed in the template files as well...Versions
10.0.3
^2.6.3
&github:netlify/next-on-netlify#ll/i18n
Related
The text was updated successfully, but these errors were encountered: