wnumb icon indicating copy to clipboard operation
wnumb copied to clipboard

The `to()` method does not work with strings.

Open m-spyratos opened this issue 8 years ago • 2 comments

In the documentation you have the following example:

var Format = wNumb({
    prefix: '$',
    postfix: ',-',
    thousand: ','
});

Format.to ( '90000' );
    => '$90,000,-'

Running it, instead of returning the desired result '$90,000,-', it returns false. Also, the case is not covered by your tests. https://jsfiddle.net/1ho4LsjL/

m-spyratos avatar Nov 08 '15 07:11 m-spyratos

Good observation, I'll get it fixed. Thanks!

leongersen avatar Nov 16 '15 10:11 leongersen

@leongersen Still got false in v1.1.0.

ghost avatar Sep 20 '17 06:09 ghost