feat(i18n): scaffold react-i18next with Spanish locale baseline#58
Open
Mubking-dev wants to merge 1 commit into
Open
feat(i18n): scaffold react-i18next with Spanish locale baseline#58Mubking-dev wants to merge 1 commit into
Mubking-dev wants to merge 1 commit into
Conversation
|
@mubking is attempting to deploy a commit to the truthixify's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
@Mubking-dev Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
Contributor
|
After #59 (OG generator) just landed alongside this one, conflicts on git fetch origin
git rebase origin/develop
pnpm install # regenerates lockfile with both your i18n deps + OG deps
# Hero.tsx: keep develop's <head> additions, then re-apply your t() wrappings
git add -u
git rebase --continue
git push --force-with-lease |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Closes #27
Scaffolds full i18n support using
react-i18next, with Spanish as the first non-English locale.Changes
src/i18n/en.json— English translation source for all UI stringssrc/i18n/es.json— Spanish baseline (full structural parity with EN)src/i18n/index.ts— locale detection vialocalStorage→navigator.language→'en'src/main.tsx— imports i18n config before React renderssrc/components/*.tsx(×9) — all visible strings wrapped int()src/components/Header.tsx— EN ↔ ES switcher added next to theme togglescripts/lint-i18n.mjs— CI script; exits 1 if hardcoded JSX strings foundscripts/generate-og.mjs— post-build; emitsdist/en/anddist/es/with locale-specific OG/meta tagspackage.json— addedlint:i18nandgenerate:ogscripts.github/workflows/ci.yml—pnpm lint:i18nruns before build on every pushAcceptance criteria
en.json+es.jsoncompletelocalStoragepersistence +navigator.languagedefaultdist/en/anddist/es/)Testing