-
Notifications
You must be signed in to change notification settings - Fork 10.3k
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
Change routing to support localizations #17759
Comments
Hiya! This issue has gone quiet. Spooky quiet. 👻 We get a lot of issues, so we currently close issues after 30 days of inactivity. It’s been at least 20 days since the last update here. If we missed this issue or if you want to keep it open, please reply here. You can also add the label "not stale" to keep this issue open! As a friendly reminder: the best way to see this issue, or any other, fixed is to open a Pull Request. Check out gatsby.dev/contribute for more information about opening PRs, triaging issues, and contributing! Thanks for being a part of the Gatsby community! 💪💜 |
@tesseralis I would like to work on this issue |
@nutboltu thanks for the offer, but I think this is something I need to handle myself! |
@tesseralis Cheers!. Just curious if there's any ticket I can tackle regarding translation docs. |
Actually... @nuboltu if you want to take a shot at this, be my guest. The barrier I ran into was that the source takes so long to build that it was difficult to iterate on and it made more sense for me to wait until the core team made improvements to it. I'm focused more on setting up the translation workflow now, but if you want to try your hand, go ahead! |
Thanks, @tesseralis I'll take a look 😄 |
Looking forward to seeing how this goes! I've got an MDX project that would benefit from this work once it's ready |
Fiexed as of #20637 |
Summary
Make changes to the gatsbyjs.org site's
gatsby-node
to support localized routes.Details
A lot of implementation details can be taken from the using-i18n example by @LekoArts .
Step 1
For the first step, we need to reroute all English docs to a localized
/en
path:en/
route (e.g./en/docs/quick-start
)/docs/[page]
to/en/docs/[page]
(same for tutorials and contributing)LocalizedLink
component so that links in markdown to localized files are always routed to the localized URL.Step 2
Once we are able to pull in language repos, we can then proceed to display those localized pages based on the language code:
gatsby-node
to create pages for each localized markdown fileLocalizedLink
to keep links in the current languageUnresolved Questions
/docs/community/
to/contributing/community/
). How should we deal with these when all pages are being redirected to/en
?The text was updated successfully, but these errors were encountered: