Created
August 13, 2020 08:03
-
-
Save andreferi3/83b56754ea728a38d09e2876c78f85e7 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function parseNumFormat(amount) { | |
| if(amount) { | |
| return amount.toString().replace(/\B(?=(\d{3})+(?!\d))/g, '.'); | |
| } else { | |
| return 0 | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment