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

feat(gatsby-theme-i18n): Localized matchPath & LocalizedRouter #64

Merged
merged 8 commits into from
Sep 14, 2020

Conversation

jgfidelis
Copy link
Contributor

https://www.gatsbyjs.com/docs/gatsby-internals-terminology/#matchpath

the matchPath prop on the page being created was not being modified (by adding /langCode/ to the start of matchPath)

This would cause client pages not being properly found and when accessing /langCode/client-page-url

@jgfidelis
Copy link
Contributor Author

@aaaakshat would you mind merging this?

Also, do you expect to release a version with this fix soon? It would really help us.

Copy link
Contributor

@bitmaks bitmaks left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey there, apologies but I'm not Gatsby staff. I was a maintainer when I merged your previous PR; however Gatsby recently underwent a organisational restructure (blog post here).

The new structure will only let Gatsby staff handle write access to repos so someone from the team should hopefully review this soon.

@LekoArts LekoArts changed the title theme-i18n: onCreatePage, append locale to matchPath as well feat(gatsby-theme-i18n): Localized matchPath & LocalizedRouter Sep 11, 2020
@LekoArts
Copy link
Contributor

Thanks for the PR! I added example code to the default example and also added a LocalizedRouter so that nested paths also work. Your initial code for the matchPath also works :)

I'll release this on monday then!

@LekoArts LekoArts merged commit cf54dcf into gatsbyjs:master Sep 14, 2020
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

Successfully merging this pull request may close these issues.

3 participants