Releases
v3.0.0
Release 3.0.0: CountryCode enum migration
Latest
Compare
Sorry, something went wrong.
No results found
[3.0.0] - 2025-10-02
Added
CountryCode enum replacing raw string codes.
FormatterRegistry redesigned to be immutable (register() returns a new instance).
FormatterRegistry::all() method for inspecting registered formatters.
Full PHPUnit test coverage for registry immutability and enum integration.
Changed
BC BREAK : All methods now expect CountryCode instead of string country codes.
BC BREAK : FormatterRegistry no longer has static state – must be instantiated and passed into PostcodeFormatter.
PostcodeFormatter now requires a FormatterRegistry instance in its constructor.
Fixed
Clearer distinction between UnknownCountryException and UnsupportedCountryException.
Improved error messages with translation keys (error.invalid_postcode, error.unknown_country, error.unsupported_country).
Tests
✅ Full PHPUnit coverage (100%).
✅ PHPStan Level 10 + Strict Rules passing with 0 errors.
You can’t perform that action at this time.