Answers for "convert string number to local number with commas js"

4

javascript number to number with commas

var number = 3500;

console.log(number.toLocaleString());
Posted by: Guest on May-25-2021
3

format number with commas js

foramtNumber = (num,div=",")=>{
  return num.toString().replace(/\B(?=(\d{3})+(?!\d))/g, div);

}
Posted by: Guest on December-10-2020

Code answers related to "convert string number to local number with commas js"

Code answers related to "Javascript"

Browse Popular Code Answers by Language