Skip to main content

Interface: FormatOptions

Defined in: number/types.ts:28

Options for formatting numbers.

Properties

decimals?

readonly optional decimals: number

Defined in: number/types.ts:33

Number of decimal places to display.

Default

2

locale?

readonly optional locale: string

Defined in: number/types.ts:45

Locale to use for formatting.

Default

'en-US'

maximumFractionDigits?

readonly optional maximumFractionDigits: number

Defined in: number/types.ts:55

Maximum number of decimal places.


minimumFractionDigits?

readonly optional minimumFractionDigits: number

Defined in: number/types.ts:50

Minimum number of decimal places.


useGrouping?

readonly optional useGrouping: boolean

Defined in: number/types.ts:39

Whether to use grouping separators (e.g., commas).

Default

true