NumberFormat.compact constructor

NumberFormat.compact({
  1. String? locale,
})

A number format for compact representations, e.g. "1.2M" instead of "1,200,000".

Implementation

factory NumberFormat.compact({String? locale}) {
  return _CompactNumberFormat(
      locale: locale,
      formatType: _CompactFormatType.COMPACT_DECIMAL_SHORT_PATTERN);
}