Prompt
Ensure all placeholders in localization files follow consistent naming conventions to prevent runtime errors and text leakage in the UI. This applies to both sprintf-style placeholders (%s) and template variables ({{name}}).
Common issues to watch for:
-
Correct sprintf order: Use
%snots%-"emails.invitation.subject": "Invitació a l'equip %s a s%", +"emails.invitation.subject": "Invitació a l'equip %s a %s",
Placeholder errors are particularly problematic because they can:
- Break runtime string substitution
- Cause literal placeholder text to appear in the UI
- Lead to crashes in formatting functions
- Create inconsistent user experiences across languages