Bosca / Localization

Strings & Translations

Keys, context, correct plurals

A string is more than a line of text to translate. It carries the context a translator needs, the rules a variable follows, and the plural forms a language actually uses — so what ships reads right, everywhere.

More than text

Everything a translator needs to get it right

Each string has a stable key and travels with the context around it — a note on where it appears, a character limit for tight UI, tags to group it, and even a screenshot, so a translator is never guessing what they're translating.

  • A stable key identifies the string; its text is free to change underneath.
  • Context notes, tags, and a maximum length guide the translation.
  • Attach a screenshot or reference so the translator sees it in place.
string · checkout.pay
keycheckout.pay
contextprimary button on the checkout screen
max 20checkoutcta
screenshot attached

Typed placeholders

Variables that don't break

When a string has a variable, it's declared — with a type and an example. A translator knows that {count} is a number and {date} is a date, so the placeholder survives the translation intact, in the right place for the language.

  • Placeholders declare a type — number, date, time, or currency.
  • An example value shows the translator what to expect.
  • Built on ICU MessageFormat, the standard for this.
placeholder

You have {count} items in your cart

countnumbere.g. 3

Plurals done right

One, few, many — per language

"1 item" and "5 items" aren't the same shape, and languages disagree on how many shapes there are. Bosca keeps a separate value for each CLDR plural category, so a language uses exactly the forms it needs — no cramming it all into one string.

  • Every CLDR category — zero, one, two, few, many, other — is editable on its own.
  • Each language uses just the forms its rules call for.
  • Exporters emit the right plural shape for each target platform.
cart.items · en
one1 item
other{count} items

English uses one + other; other languages use more

Keep exploring

More on Localization