Skip to main content
The renderer turns raw values into display text — numbers, dates and currencies — locale-aware. The engine emits raw values; formatting happens here, at paint time.

Two locales

Two locales are in play:
  • Parsing locale — how ambiguous input is interpreted (is 01/02/2024 Jan 2 or Feb 1?). Set on the data via data._metadata.parsingLocale; defaults to en-GB.
  • Formatting locale — how output is displayed (separators, month names, currency symbols). Set with the formattingLocale prop on GraphProvider.
When you don’t set formattingLocale, display falls back to the parsing locale.

Supported locales

en-GB, en-US, ar, pt-PT.

What a locale drives

The resolved locale — formattingLocale ?? parsingLocale — reaches two separate layers:
  • Value formatting — numbers, dates and currency symbols in axis labels, tooltips, data labels and headline numbers.
  • UI strings — the renderer’s own phrases, such as the headline’s comparison wording. Translations ship for en-GB, en-US, ar and pt-PT.
Two independent fallbacks apply to the strings. A locale outside the supported set resolves to en-GB as a whole, and within a resolved locale a phrase with no translation falls back to the en-GB wording for that phrase alone.
Dates render in UTC, always. A host in UTC+13 reading a timestamp near midnight sees the UTC calendar day, not the local one — pre-shift timestamps in your data if you need local days.
The duration value format is always English, whatever the locale.

Number formatting

Locale governs separators and symbols; the numberFormat config governs the rest, and can override the locale’s separators when you need to:
number | 'auto'
default:"auto"
Fixed decimal places, or 'auto' to choose from the value’s magnitude.
'auto' | 'k' | 'm' | 'b' | 'none'
'auto' abbreviates from magnitude (1234567 → 1.2M); 'k', 'm' and 'b' force a unit; 'none' writes the number in full.
string
Overrides the locale’s grouping separator.
string
Overrides the locale’s decimal separator.
string
Text prepended to the formatted number, e.g. '$'.
string
Text appended to the formatted number, e.g. '%'.

Currencies and dates

Currency and date columns detected during value-format inference are formatted for the active locale automatically — a £1,250 column renders with the right symbol and grouping, a date axis with locale-appropriate month names — without extra configuration.