Numeral.js for Number Formatting in JavaScript and TypeScript

Tadashi Shigeoka ·  Thu, January 28, 2021

I’ll introduce Numeral.js, a library for number formatting in JavaScript/TypeScript.

npm

Background: Need to Format Numbers in JavaScript and TypeScript

I think you often need to format numbers in JavaScript and TypeScript.

When comparing several npm packages, Numeral.js looked promising and it also supports TypeScript, so I decided to use this one.

number format.js vs number formatter vs numeral vs numeraljs | npm trends

Number Formatting in JavaScript with Numeral.js

Number Formatting in TypeScript with @types/numeral

That’s all from wanting to use Numeral.js for number formatting in JavaScript and TypeScript from the Gemba.