Interface NumberFormatOptions
interface NumberFormatOptions {
compactDisplay?: "short" | "long";
currency?: string;
currencyDisplay?: keyof NumberFormatOptionsCurrencyDisplayRegistry;
currencySign?: "standard" | "accounting";
localeMatcher?: "lookup" | "best fit";
maximumFractionDigits?: number;
maximumSignificantDigits?: number;
minimumFractionDigits?: number;
minimumIntegerDigits?: number;
minimumSignificantDigits?: number;
notation?:
| "standard"
| "scientific"
| "engineering"
| "compact";
numberingSystem?: string;
roundingIncrement?:
| 1
| 2
| 5
| 10
| 20
| 25
| 50
| 100
| 200
| 250
| 500
| 1000
| 2000
| 2500
| 5000;
roundingMode?:
| "ceil"
| "floor"
| "expand"
| "trunc"
| "halfCeil"
| "halfFloor"
| "halfExpand"
| "halfTrunc"
| "halfEven";
roundingPriority?: "auto" | "morePrecision" | "lessPrecision";
signDisplay?: keyof NumberFormatOptionsSignDisplayRegistry;
style?: keyof NumberFormatOptionsStyleRegistry;
trailingZeroDisplay?: "auto" | "stripIfInteger";
unit?: string;
unitDisplay?: "short" | "long" | "narrow";
useGrouping?:
| boolean
| "false"
| (keyof NumberFormatOptionsUseGroupingRegistry)
| "true";
}
compactDisplay?: "short" | "long";
currency?: string;
currencyDisplay?: keyof NumberFormatOptionsCurrencyDisplayRegistry;
currencySign?: "standard" | "accounting";
localeMatcher?: "lookup" | "best fit";
maximumFractionDigits?: number;
maximumSignificantDigits?: number;
minimumFractionDigits?: number;
minimumIntegerDigits?: number;
minimumSignificantDigits?: number;
notation?:
| "standard"
| "scientific"
| "engineering"
| "compact";
numberingSystem?: string;
roundingIncrement?:
| 1
| 2
| 5
| 10
| 20
| 25
| 50
| 100
| 200
| 250
| 500
| 1000
| 2000
| 2500
| 5000;
roundingMode?:
| "ceil"
| "floor"
| "expand"
| "trunc"
| "halfCeil"
| "halfFloor"
| "halfExpand"
| "halfTrunc"
| "halfEven";
roundingPriority?: "auto" | "morePrecision" | "lessPrecision";
signDisplay?: keyof NumberFormatOptionsSignDisplayRegistry;
style?: keyof NumberFormatOptionsStyleRegistry;
trailingZeroDisplay?: "auto" | "stripIfInteger";
unit?: string;
unitDisplay?: "short" | "long" | "narrow";
useGrouping?:
| boolean
| "false"
| (keyof NumberFormatOptionsUseGroupingRegistry)
| "true";
}
Index
Properties
compactDisplay?
currency?
currencyDisplay?
currencySign?
localeMatcher?
maximumFractionDigits?
maximumSignificantDigits?
minimumFractionDigits?
minimumIntegerDigits?
minimumSignificantDigits?
notation?
numberingSystem?
roundingIncrement?
roundingMode?
roundingPriority?
signDisplay?
style?
trailingZeroDisplay?
unit?
unitDisplay?
useGrouping?
Properties
Optional
compactDisplay
compactDisplay ?: "short" | "long"
Optional
currency
currency?: string
Optional
currencyDisplay
Optional
currencySign
currencySign ?: "standard" | "accounting"
Optional
localeMatcher
localeMatcher ?: "lookup" | "best fit"
Optional
maximumFractionDigits
maximumFractionDigits ?: number
Optional
maximumSignificantDigits
maximumSignificantDigits ?: number
Optional
minimumFractionDigits
minimumFractionDigits ?: number
Optional
minimumIntegerDigits
minimumIntegerDigits ?: number
Optional
minimumSignificantDigits
minimumSignificantDigits ?: number
Optional
notation
notation?:
| "standard"
| "scientific"
| "engineering"
| "compact"
| "standard"
| "scientific"
| "engineering"
| "compact"
Optional
numberingSystem
numberingSystem ?: string
Optional
roundingIncrement
roundingIncrement ?:
| 1
| 2
| 5
| 10
| 20
| 25
| 50
| 100
| 200
| 250
| 500
| 1000
| 2000
| 2500
| 5000
| 1
| 2
| 5
| 10
| 20
| 25
| 50
| 100
| 200
| 250
| 500
| 1000
| 2000
| 2500
| 5000
Optional
roundingMode
roundingMode ?:
| "ceil"
| "floor"
| "expand"
| "trunc"
| "halfCeil"
| "halfFloor"
| "halfExpand"
| "halfTrunc"
| "halfEven"
| "ceil"
| "floor"
| "expand"
| "trunc"
| "halfCeil"
| "halfFloor"
| "halfExpand"
| "halfTrunc"
| "halfEven"
Optional
roundingPriority
roundingPriority ?: "auto" | "morePrecision" | "lessPrecision"
Optional
signDisplay
Optional
style
Optional
trailingZeroDisplay
trailingZeroDisplay ?: "auto" | "stripIfInteger"
Optional
unit
unit?: string
Optional
unitDisplay
unitDisplay ?: "short" | "long" | "narrow"
Optional
useGrouping
useGrouping ?:
| boolean
| "false"
| (keyof NumberFormatOptionsUseGroupingRegistry)
| "true"
| boolean
| "false"
| (keyof NumberFormatOptionsUseGroupingRegistry)
| "true"