Interface NumberFormat
interface NumberFormat {
format(value: number | bigint | StringNumericLiteral): string;
formatRange(
start: number | bigint | StringNumericLiteral,
end: number | bigint | StringNumericLiteral,
): string;
formatRangeToParts(
start: number | bigint | StringNumericLiteral,
end: number | bigint | StringNumericLiteral,
): NumberRangeFormatPart[];
formatToParts(
value: number | bigint | StringNumericLiteral,
): NumberFormatPart[];
resolvedOptions(): ResolvedNumberFormatOptions;
}
format(value: number | bigint | StringNumericLiteral): string;
formatRange(
start: number | bigint | StringNumericLiteral,
end: number | bigint | StringNumericLiteral,
): string;
formatRangeToParts(
start: number | bigint | StringNumericLiteral,
end: number | bigint | StringNumericLiteral,
): NumberRangeFormatPart[];
formatToParts(
value: number | bigint | StringNumericLiteral,
): NumberFormatPart[];
resolvedOptions(): ResolvedNumberFormatOptions;
}
Index
Methods
format
- format(value: number | bigint | StringNumericLiteral): string
Parameters
- value: number | bigint | StringNumericLiteral
Returns string
formatRange
- formatRange(
start: number | bigint | StringNumericLiteral,
end: number | bigint | StringNumericLiteral,
): string Parameters
- start: number | bigint | StringNumericLiteral
- end: number | bigint | StringNumericLiteral
Returns string
formatRangeToParts
- formatRangeToParts(
start: number | bigint | StringNumericLiteral,
end: number | bigint | StringNumericLiteral,
): NumberRangeFormatPart[] Parameters
- start: number | bigint | StringNumericLiteral
- end: number | bigint | StringNumericLiteral
Returns NumberRangeFormatPart[]
formatToParts
- formatToParts(value: number | bigint | StringNumericLiteral): NumberFormatPart[]
Parameters
- value: number | bigint | StringNumericLiteral
Returns NumberFormatPart[]
resolvedOptions
- resolvedOptions(): ResolvedNumberFormatOptions
Returns ResolvedNumberFormatOptions