msisdn-formatter
Two simple function to normalize and format msisdn.
Install
$ npm install msisdn-formatter --save
Usage
; const userNumber = '+7 926 000-00-00'; console; // Prints: '9260000000'console; // Prints: '+7 (926) 000-0000'
Available formats:
- clean: 79260000000
- cleaner: 9260000000
- short: 926 000-0000
- usual: (926) 000-0000
- full: +7 (926) 000-0000
The library is built to support AMD, CommonJS and globals.