1 min read

Angular-numeraljs 2.0

Some time back, I wrote an Angular.js library to wrap Numeral.js. I'm a big fan of Numeral for formatting numbers.

My wrapper adds a new filter to conveniently apply Numeral formats in your view:

<p>
    {{ price | numeraljs:'$0,0.00' }}
</p>

Pretty simple, but I wrote it so you don't have it. It is the cleverly-named angular-numeraljs, and has a modest following on GitHub.

Much to my surprise, Numeral recently dropped a 2.0 release after a 3-year hiatus. With a little prompting from the GitHub community, I just released a corresponding 2.0 version which will track Numeral's 2.0 branch.

There are a few breaking changes, both in the Numeral library as well as in my wrapper. I took the opportunity to revise the angular-numeraljs interface to more closely match that of Numeral itself.

The release is now available on GitHub, bower, and npm.