Skip to content

formatValue()

function formatValue(
value,
format,
locale?
): string;

Formats a value with a template ValueFormat. Values that cannot be converted (e.g. text with a number format) fall back to toDisplayString.

Parameter Type Default value
value unknown undefined
format ValueFormat | undefined undefined
locale string DEFAULT_LOCALE

string