money2 1.0.0-beta.5 copy "money2: ^1.0.0-beta.5" to clipboard
money2: ^1.0.0-beta.5 copied to clipboard

outdated

A user friendly implementation of LitGroup's Dart Money. Provides Money and Currency classes with fixed precision maths operations and a nice Money formatter.

example/example.dart

import 'package:money2/money2.dart';

void main() {
  final usd = Currency.create('USD', 2);
  Money costPrice = Money.fromInt(10034530, usd); // 100,345.30 usd

  costPrice.format("###,###.##");
// > 100,345.30

  costPrice.format("S###,###.##");
// > $100,345.3

  costPrice.format("CC###,###.#0");
// > US100,345.30
}
172
likes
0
pub points
96%
popularity

Publisher

verified publisheronepub-web.flutter-io.cn

A user friendly implementation of LitGroup's Dart Money. Provides Money and Currency classes with fixed precision maths operations and a nice Money formatter.

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

intl

More

Packages that depend on money2