v1.0.0 (2026-07-20)

This fork is rebranded from Number/:number to NumberFormatter/:number_formatter, published as a new Hex package (number_formatter), so versioning restarts at 1.0.0 rather than continuing upstream's 1.0.x line. Everything below is relative to upstream v1.0.5.

Breaking changes:

  • Renamed every module (Number -> NumberFormatter) and their backing files (lib/number(.ex|/) -> lib/number_formatter(.ex|/), same under test/).
  • Renamed the OTP application/config atom from :number to :number_formatter. Existing config :number, ... must become config :number_formatter, ....
  • Package renamed from number to number_formatter; repo moved to Ch4s3/number_formatter.
  • Upgraded decimal to ~> 3.0, dropping support for ~> 1.5/~> 2.0.
  • Tightened the elixir version requirement from ~> 1.0 to ~> 1.16, matching what's actually tested in CI.

Added:

  • Elixir 1.20 support, tested in CI alongside 1.16.
  • CI migrated from Semaphore to GitHub Actions.
  • Credo static analysis, run as part of bin/test.
  • Test coverage for the use NumberFormatter macro (previously untested).

Fixed:

  • Conversion.to_float/1 and to_decimal/1 no longer silently truncate malformed strings with a valid numeric prefix -- to_decimal("123abc") used to return Decimal.new(123); it now raises ArgumentError.
  • Fixed a Decimal.Error crash in number_to_delimited/2 and number_to_currency/2 on float-derived strings with more than 28 significant digits (Decimal 3.x's default max_digits).
  • Fixed backreference corruption in Currency.number_to_currency/2 and Phone.number_to_phone/2 when a :unit or :delimiter option contained a literal backslash-digit sequence (e.g. "\1"), which was silently misread as a regex capture-group reference.
  • Fixed Elixir 1.19+ deprecation warnings (preferred_cli_env -> cli/0, single-quoted charlists -> ~c sigil).

Changed:

  • Removed the dead Decimal 1.x compare/2 compatibility shim; call sites now use Decimal.compare/2 directly.
  • Simplified Human.number_to_human/2 (cyclomatic complexity 11 -> a data-driven scale list) and Delimit.to_integer/1 (explicit try -> idiomatic implicit try).
  • Extracted repeated config-loading boilerplate (5 modules) into NumberFormatter.Config.resolve/2.

v1.0.5 (2024-04-06)

Full Changelog

Merged pull requests:

v1.0.4 (2023-05-26)

Full Changelog

Merged pull requests:

v1.0.3 (2020-10-01)

Full Changelog

Closed issues:

  • Broken behavior with Decimal version 1.x #47
  • Decimal 2.0 has been released, Number requires ~>1.5 #45

Merged pull requests:

v1.0.2 (2020-09-21)

Full Changelog

Merged pull requests:

v1.0.1 (2019-12-06)

Full Changelog

Closed issues:

  • number_to_delimited shows 2 decimal places. Readme says otherwise. #43
  • Changelog entry for 1.0.0 #41

Merged pull requests:

v1.0.0 (2018-11-28)

Full Changelog

Closed issues:

  • Rounding fails #38

Merged pull requests:

v0.5.7 (2018-05-17)

Full Changelog

Merged pull requests:

v0.5.6 (2018-04-19)

Full Changelog

Merged pull requests:

v0.5.5 (2018-02-19)

Full Changelog

Closed issues:

  • Invalid typespecs #34

Merged pull requests:

  • Use Number.t to fix type specs #35 (jclem)

v0.5.4 (2017-09-07)

Full Changelog

Closed issues:

  • decimal_arithmetic is missing from applications list #32

Merged pull requests:

v0.5.3 (2017-08-30)

Full Changelog

Closed issues:

  • Deprecation warnings in Elixir 1.5 #30
  • Negative Decimal problem #28

Merged pull requests:

v0.5.2 (2017-08-05)

Full Changelog

Closed issues:

  • Number formatting with abbreviations: $1,200,000 -> $1.2MM, $5,586 -> $5.6k, etc. #26

Merged pull requests:

v0.5.1 (2017-01-17)

Full Changelog

Closed issues:

  • Add to application list in mix.exs? #23

Merged pull requests:

v0.5.0 (2016-11-26)

Full Changelog

Closed issues:

  • Error in hex doc #16

Merged pull requests:

v0.4.2 (2016-07-02)

Full Changelog

Fixed bugs:

  • Number.Conversion is not used internally #12

Closed issues:

  • Module not available in releases if not listed in :applications #14

Merged pull requests:

v0.4.1 (2015-12-16)

Full Changelog

Closed issues:

  • number_to_human skips some numbers #10

Merged pull requests:

v0.4.0 (2015-08-04)

Full Changelog

Merged pull requests:

v0.3.4 (2015-06-10)

Full Changelog

v0.3.3 (2015-06-10)

Full Changelog

v0.3.2 (2015-06-10)

Full Changelog

Implemented enhancements:

v0.3.1 (2015-06-10)

Full Changelog

v0.3.0 (2015-06-10)

Full Changelog

Implemented enhancements:

Merged pull requests:

v0.2.1 (2015-06-09)

Full Changelog

v0.2.0 (2015-06-09)

Full Changelog

* This Changelog was automatically generated by github_changelog_generator