You can use NumberFormat() to set the number format to be displayed.
let numberFormat = new Intl.NumberFormat('zh-CN'); console.info(`numfmt: ${numberFormat.format(1000000)}`);
Reference
NumberFormat