NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
pub.dev · #449 most downloaded on pub.dev
The decimal package allows you to deal with decimal numbers without losing precision.
Last release 2 months ago
28 Jul 2026
Release timing varies
gaps range from 2 weeks to 13 months
Most releases are documented
notes for 35 of 43 stable releases
Nothing withdrawn
no release was ever pulled
14 years old
44 releases · first in 2013
Speed up round/floor/ceil/truncate by rounding on the significand
Fix toStringAsPrecision emitting an extra digit on power-of-10 carry
Fix issue with scale of zero causing problem in addition/substraction with zero.
One column per quarter.
Fix bad scale value by parsing 0.0 (see Issue with Decimal.tryParse return value formatting)
0.0 (see Issue with Decimal.tryParse return value formatting)loosen intl to >=0.19.0 <0.21.0 to address Intl version within flutter_localizations makes version 3.2.1 of decimal impossible to use on Flutter v3.29
intl to >=0.19.0 <0.21.0 to address Intl version within flutter_localizations makes version 3.2.1 of decimal impossible to use on Flutter v3.29.3lints to 5.0.0Decimal.zero, Decimal.one, and Decimal.ten finalfix: toString() method for values < 0.1
- Improve performances
Bump intl to 0.20.0, lints to 5.0.0
intl to 0.20.0, lints to 5.0.0Fix #107: avoid exception when formatting decimal with NumberFormat.compact().
NumberFormat.compact().Throw FormatException on formatter.parse('NaN').
FormatException on formatter.parse('NaN').Add DecimalFormatter to deal with intl package. Your can now parse and format decimals.
DecimalFormatter to deal with intl package. Your can now parse and format decimals.Introduce logical operators to DecimalIntl to support intl 0.18.0
Update files according to license.
Update license file to be recognized by pub.dev.
(Breaking change) Fix Decimal.pow return type. This method now returns a Rational because 3.pow(-1) (similar to 1/3) could not be represented as a Dec…
Decimal.pow return type. This method now returns a Rational because 3.pow(-1) (similar to 1/3) could not be represented as a Decimal.Rational.toDecimal() customization via its new toBigInt parameter.Fix toStringAsExponential returned 10.00e+7 instead of 1.00e+8
Fix toStringAsExponential returns INFINITY by implementing toStringAsExponential without relying on double implementation.
toStringAsExponential without relying on double implementation.zero.precision == 1.Fix `toString` issue with negative number between 0 and -1
It introduces several breaking changes.
The goal of this version is to have sharper types on the API and to avoid having [Decimal] objects that are not decimal numbers (1/3 for instance).
It introduces several breaking changes.
~/ now returns a BigInt. If you need a Decimal you can convert the BigInt to Decimal with bigint.toDecimal().isNaN getter. It was always returning false.isInfinite getter. It was always returning false.isNegative getter. You can replace it with decimal < Decimal.zero.inverse, / now return a Rational. If you need a Decimal you can convert the Rational to Decimal with rational.toDecimal(scaleOnInfinitePrecision: xxx). If you need to make several computations where inverses or divisions are involved you should make thoses operations on Rational type to avoid loosing precision and at the end convert the result back to Decimal if you want to display the result in a decimal form.Other changes:
round(), floor(), ceil(), truncate() now accept an optional scale to indicate at which digit the operation should be done.shift to move the decimal point.hasFinitePrecision on Rational to know if a decimal form of the rational is possible without loosing precision.toDecimal() on Rational.toDecimal() on int.toDecimal() on BigInt.Support json serialization as String with Decimal.fromJson/Decimal.toJson.
Decimal.fromJson/Decimal.toJson.- Add Decimal.ten. - Add Decimal.toBigInt.
Decimal.ten.Decimal.toBigInt.- Add Decimal.fromBigInt.
Decimal.fromBigInt.Add DecimalIntl to allow formatting with intl package.
DecimalIntl to allow formatting with intl package.Allow negative value as exponent of pow.
pow.Fix typo in the description of the package.
- Stable null safety release.
- Migrate to nullsafety.
- add `Decimal.pow`.
add Decimal.zero and Decimal.one.
Decimal.zero and Decimal.one.Decimal.inverse.- add Decimal.tryParse.
Decimal.tryParse.- migration to Dart 2.
make Decimal.parse a factory constructor.
Decimal.parse a factory constructor.- allow parsing of 1.
1.- move to Dart SDK 2.0
- make package strong clean
- add Decimal.signum - add Decimal.hasFinitePrecision - add Decimal.precision - add Decimal.scale
Decimal.signumDecimal.hasFinitePrecisionDecimal.precisionDecimal.scaleNothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Your coding agent can read these notes before it upgrades. Set up the MCP server →