string-mask
string-mask copied to clipboard
Some of the examples are not working
var formatter = new StringMask('#0,00%');
var result = formatter.apply('001'); // 0,01%
the result is empty.
var formatter = new StringMask('#0');
var result = formatter.apply('123'); // 123
gives 12 instead of 123.
var formatter = new StringMask('UUUUUUUUUUUUU');
var result = formatter.apply('To Upper Case'); // TO UPPER CASE
give TO
I'm using in on react native (which shouldn't be important really but I thought it's better I mention it).