@react-input/number-format
Version:
React input component for formatted number input with locale-specific.
13 lines (12 loc) • 418 B
TypeScript
import { Input } from '@react-input/core';
import type { NumberFormatOptions } from './types';
export default class NumberFormat extends Input<{
locales: Intl.LocalesArgument;
options: NumberFormatOptions;
}> {
format: (value: number | bigint | string) => string;
unformat: (value: string) => string;
constructor(_options?: NumberFormatOptions & {
locales?: Intl.LocalesArgument;
});
}