Convert a Number to a string with commas.
MIT License
Convert a Number to a string with commas.
$ npm install number-with-commas --save
import numberWithCommas from 'number-with-commas';
t.is(numberWithCommas(10000), '10,000');
t.is(numberWithCommas(-10000), '-10,000');
t.is(numberWithCommas(1000.1001), '1,000.1,001');
numberWithCommas(
x: number,
): string
$ npm run lint
$ npm run test:watch
$ npm test
).