formatWithCustomPattern method

String formatWithCustomPattern(
  1. String pattern, {
  2. String? locale,
})

Formats the number using a custom pattern with the given locale.

Implementation

String formatWithCustomPattern(String pattern, {String? locale}) {
  return NumberFormat(pattern, locale).format(this);
}