locales 0.0.1 copy "locales: ^0.0.1" to clipboard
locales: ^0.0.1 copied to clipboard

discontinuedreplaced by: intl
outdated

Locale codes and ISO 4217 currency codes.

locales #

Locale codes and ISO 4217 currency codes.

Example #

import 'package:locales/locales.dart';
import 'package:locales/currency_codes.dart';
import 'package:intl/intl.dart';

void main() {
  final locale = Locales.english_united_states;
  final currencyCode = CurrencyCodes.united_states_dollar;
  final format = NumberFormat.simpleCurrency(
      locale: '$locale', name: '$currencyCode', decimalDigits: 2);
  print(locale);                  // en_US
  print(currencyCode);            // USD
  print(format.format(123.456));  // $123.46
}

0
likes
0
pub points
25%
popularity

Publisher

unverified uploader

Locale codes and ISO 4217 currency codes.

Repository (GitHub)
View/report issues

License

unknown (license)

More

Packages that depend on locales