Skip to content

[Frontend] i18n.config.ts has no fallback when a locale JSON file fails to load #1503

Description

@grantfox-oss

Join our community: https://t.me/+DOylgFv1jyJlNzM0

Why this matters
frontend/i18n.config.ts dynamically imports the messages file for a locale with no try/catch. If a locale segment resolves to a value outside en, es, tl, or the file is missing or malformed, the import throws unhandled and the request errors instead of falling back to English.

Acceptance criteria

  • Wrap the dynamic import in a try/catch
  • Fall back to frontend/messages/en.json on failure
  • Add a unit test covering the fallback path

Files to touch

  • frontend/i18n.config.ts

Out of scope
Adding new locales.

Metadata

Metadata

Assignees

No one assigned

    Labels

    frontendIssues related to frontend developmentgood first issueGood for newcomers

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions