import { NUMBER } from "https://deno.land/x/fluent@0.0.1/bundle/builtins.ts";
The implementation of the NUMBER()
builtin available to translations.
Translations may call the NUMBER()
builtin in order to specify formatting
options of a number. For example:
pi = The value of π is {NUMBER($pi, maximumFractionDigits: 2)}.
The implementation expects an array of FluentValues
representing the
positional arguments, and an object of named FluentValues
representing the
named parameters.
The following options are recognized:
unitDisplay
currencyDisplay
useGrouping
minimumIntegerDigits
minimumFractionDigits
maximumFractionDigits
minimumSignificantDigits
maximumSignificantDigits
Other options are ignored.
Parameters
args: Array<FluentValue>
The positional arguments passed to this NUMBER()
.
opts: Record<string, FluentValue>
The named argments passed to this NUMBER()
.