Is there a way to get number.toLocaleString() with 4 digits after the comma?
number.toLocaleString()
Example:
var number = 49.9712; document.getElementById(\'id
Quick solution:
call it like this:
console.log(localeN(value, 4));
function localeN(v, n) { var i, f; i = Math.floor(v); f = v - i; return i.toLocaleString() + f.toFixed(n).substr(1); }