commas

1.0.1 • Public • Published

Commas

Add, Remove, Replace commas.

Installation

To install commas you need to use a node package manager as npm or yarn

    $ npm install commas --save
    # YARN  
    $ yarn add commas

Usage

See more in the example folder

const cm = require('commas');
 
let n = {
  wComma: "1,000,000",
  nComma: 1000000
}
 
= cm.add(number.nComma);
//=> 1000000 to "1000000"
// return string
 
= cm.remove(number.wComma);
//=> "1,000,000" to 1000000
// return number
 
= cm.replace(number.wComma);
//=> "1,000,000" to 1.000.000
// return number

Readme

Keywords

none

Package Sidebar

Install

npm i commas

Weekly Downloads

3

Version

1.0.1

License

MIT

Last publish

Collaborators

  • rawnly