amountFormat method

String amountFormat({
  1. int digit = 0,
})

Format number with thousand separators

digit Number of decimal places to show (default: 0)

Example:

1234567.amountFormat(); // Returns: '1,234,567'

Implementation

String amountFormat({int digit = 0}) {
  return NumberUtils.amountFormat(this, digit: digit);
}