pyaesoneaung/laravel-myanmar-tools
A Laravel package of Myanmar localization utilities, offering validation and helpers for NRC numbers, phone numbers, addresses, names, currency, and dates—helping apps handle Myanmar-specific data consistently.
Package profile (assumed, to verify). pyaesoneaung/laravel-myanmar-tools is a convenience layer that extends Laravel core primitives with Myanmar-specific behavior. Based on the description and typical packages in this space, expect a subset of: NRC (national registration card) format validation, Myanmar phone number validation/normalization (MPT, Telenor, Ooredoo, Mytel prefixes), Unicode ↔ Zawgyi transliteration, Myanmar calendar date helpers, and Myanmar numeral/currency formatting. Confirm the actual feature inventory before committing to a design that depends on any of it.
Architecture fit. The integration surface is shallow and idiomatic: a service provider, likely package:discover auto-registration, and extension of Validator, Str, Number, or Blade directives via macros. That means it fits Laravel cleanly and requires no infrastructure — no queue, no storage, no external calls. The architectural concern is that macro-based extension mutates global container state at boot. Two packages registering the same macro name (Str::toZawgyi, Validator::myanmarPhone) will collide, and the failure mode is a boot-time BadMethodCallException or, worse, silent override of another package's behavior. Treat macro namespace collisions as a real integration risk, not a theoretical one.
Integration feasibility. Low friction. composer require, optional vendor:publish for config and lang files, no credentials, no migrations. The binding constraints are the composer.json PHP and illuminate/* version ranges — verify against the target Laravel majors. Stars (29) and dependents (0) mean there is essentially no production evidence base, so feasibility must be established by our own test harness, not by ecosystem adoption.
Technical risk.
Key questions for the maintainer.
composer.json constraints for PHP and Laravel majors; is Laravel 12 supported?Stack fit. Use only in Laravel services that actually touch Myanmar user data — registration, KYC, notifications/SMS, address capture, and reporting. There is no reason to install it fleet-wide; a package that globally registers macros and lang files adds boot cost and collision surface to every app that loads it.
Migration approach.
App\Support\Myanmar\Formatter, MyanmarValidator) so no domain code references package symbols directly. This is the single highest-value decision — it converts a bus-factor-1 dependency into a swappable implementation detail and lets us fork, patch, or reimplement without touching product code."pyaesoneaung/laravel-myanmar-tools": "x.y.z") rather than a caret range, given zero downstream dependents and no evidence of semver discipline.+95, leading zero, 09 prefix, whitespace/hyphen variants), and Unicode↔Zawgyi pairs asserted for round-trip and for idempotency. This suite is what makes the risk assessment empirical.Compatibility. Verify auto-discovery does not double-register if we also add the provider manually. Check that published lang/my_MM files merge cleanly with app-level translations and do not override existing keys. If the package defines global Blade directives or Str macros, grep existing packages for the same names.
Sequencing.
Maintenance. Budget roughly 0.05–0.1 FTE ongoing, rising to 0.25 FTE if we end up owning reference data (carrier prefixes, township codes) or forking. Dependabot will surface releases we must triage manually — small surface, but no upstream signal to lean on. Assume we are the de facto maintainer of last resort.
Support. No vendor, no SLA, no community forum. Internal Tier-1 support must own questions like "why was this NRC rejected." Publish an internal short doc with the adapter API and the validation rules, or the package's behavior becomes tribal knowledge. Add a runbook entry for "validation behavior changed after dependency bump."
Scaling. Pure PHP string/regex work; runtime cost is negligible per request. The one place to watch is bulk paths — transliteration and formatting applied per-row across large imports or report generation is linear and measurable. Benchmark the 100k-row case in the spike; if conversion is expensive, normalize once at ingestion rather than on every read, and store both the source and normalized forms.
Failure modes.
composer.lock discipline, and the fork escape hatch.Ramp-up. Low for engineers — a Laravel developer is productive in under a day, and the adapter boundary means only one or two people ever need to know the package internals. The real ramp-up cost is domain: whoever owns this needs to understand Myanmar encoding history and NRC/township structure, not just the API. That is a 2–3 day reading investment for the designated owner, and it is the prerequisite for judging whether the golden-file suite is actually adequate.
Recommendation. Adopt conditionally: isolate behind an adapter, pin exactly, prove correctness with our own fixtures in a one-week spike, and pilot in a single bounded workflow. Do not adopt fleet-wide, and do not adopt at all unless the spike confirms the fixture corpus passes and we have a fork path secured.
How can I help you explore Laravel packages today?