numCommaParse method

dynamic numCommaParse(
  1. dynamic number
)

Implementation

numCommaParse(number) {
  return number.round().toString().replaceAllMapped(
      new RegExp(r'(\d{1,3})(?=(\d{3})+(?!\d))'), (Match m) => "${m[1]},");
}