Releases: ay4t/php-helpers
Releases · ay4t/php-helpers
2.0.2
Changelog — v2.0.2 (2025-08-22)
✨ Added
- Shipping Container Checker (ISO 6346) (
Validation\ShippingContainerChecker
) [33391d7]- Validasi dan hitung check digit.
- Input fleksibel: “CSQU3054383”, “CSQU305438”, “CSQU 305438 3”.
- Output ternormalisasi via getResult().
- Dokumentasi: docs/Validation/ShippingContainerChecker.md.
- Contoh CLI: examples/shipping_container_example.php.
- StringHelper::toBoolean() [33a69ed]
- Konversi string ke boolean mendukung “true/false”, “yes/no”, “on/off”, “t/f”, “y/n”, numerik 1/0 dan non-zero/zero.
- Default fallback via parameter opsional.
- Mendukung method chaining.
🔧 Changed
- Facade HP kini memuat namespace:
HTML
,Security
,URL
,Validation
[7f26709]. - Phone Helper: saat parse gagal, kini melempar
InvalidArgumentException
(sebelumnya\libphonenumber\NumberParseException
) [7f26709]. - ValidationHelper::isNumeric() diperkuat untuk kombinasi
allowNegative
danallowFloat
[7f26709]. - README diperbarui dengan contoh penggunaan facade terbaru [7f26709, 33391d7].
📚 Docs
- Tambah docs/Validation/ShippingContainerChecker.md [33391d7].
- Tambah link dokumentasi baru di readme.md [33391d7].
🧪 Tests
- Tambah test komprehensif untuk ShippingContainerChecker [33391d7].
- Tambah test komprehensif untuk StringHelper::toBoolean() [33a69ed].
- Update test Phone untuk exception type baru [7f26709].
🧰 Chore
- Update
.gitignore
untuk mengabaikan.phpunit.result.cache
[7f26709].
⚠️ Catatan Kompatibilitas
- Exception parsing di Phone Helper berubah menjadi
InvalidArgumentException
. Jika kode Anda mengandalkan tipe exception lama, sesuaikan handler-nya.
Referensi Commit
2.0.1
Full Changelog: 1.0.0...2.0.1
1.0.0
Full Changelog: https://github.com/ay4t/php-helpers/commits/1.0.0