UNPKG

@numio/bigmath

Version:

@numio/bigmath is an arbitrary-precision arithmetic library. It can be used for basic operations with decimal numbers (integers and float)

4 lines (3 loc) 87 B
export const isDecimal = (str) => { return /^-?(?![\.])\d+(\.\d+)?$/.test(str); };