A javascript library for formatting and manipulating numbers.
Questions tagged [numeral.js]
49 questions
1
vote
1 answer
how can I format number with at least one decimal in numeraljs
In numeraljs, I want to do that :
I need has thousand separator, in addition,
if one number has one or more decimal, just print all decimal. How many decimals is not sure.
if one number has no decimal, just add one zero as its decimal.
e.g. I want…

frank
- 1,169
- 18
- 43
1
vote
1 answer
I need a TypeScript library to, format money and numbers, perform localization operations
I'm developing a mobile application using React-Native and TypeScript super-set. I am looking for a format library in which I can perform numbers, currencies, dates, numbers and localizations.
I've used the Numeral JS library before, but the format…

Hasan Can Buyukasik
- 95
- 6
1
vote
1 answer
Bootstrap TouchSpin + NumeralJS using locale pt-br is not working
I'm trying to use bootstrap touchspin + numeraljs to set the location of my currency input to pt-br.
For this I registered a custom locale through the NumeralJS, so when I use the locale that created the increment and decrement functions do not work…

Nicolas Dias
- 641
- 11
- 22
1
vote
1 answer
How to use Numeral.js or any JS plugins in React-Native App?
I need to change a number to currency format in React-Native
this doesn't work in my case:
import Numeral from "numeral";
Numeral(100).format("$0.00")
it outputs: Metro Bundler has encountered an internal error.
I know Numeral is not built for…

DennyHiu
- 4,861
- 8
- 48
- 80
1
vote
2 answers
React input position with numeral format state
I use numeral to format my numbers from 4500000 to 4 500 000.
The problem comes with cursor position - it gets wrong when the number of spaces is changing. I tried to save cursor position when my input is change, but something is wrong with…

Mad Max
- 283
- 1
- 7
- 19
1
vote
1 answer
Need to format number only k(thausand) not m(million) or b(billion) numeraljs
We need to format number only k(thousand) not m(million) or b(billion) with numeraljs currently its converting all formats
var number = 2000000;
console.log(numeral(number).format('0a'));