import 'package:intl/intl.dart';

class NumberFormatter {
  NumberFormatter._();

  static String numberCurrency(dynamic value, String symbol, String locale, {int? decimalDigits = 2}) {
    NumberFormat numberFormat = NumberFormat.currency(locale: locale, symbol: symbol, decimalDigits: decimalDigits);
    String formatValue = numberFormat.format(value);

    return formatValue;
  }

  static compactCurrency(dynamic value, String symbol, String locale) {
    NumberFormat numberFormat = NumberFormat.compactCurrency(locale: locale, symbol: symbol);
    String formatValue = numberFormat.format(value);

    return formatValue;
  }
}