hoa/router
Hoa\Router is a standalone PHP routing component for mapping HTTP and CLI requests to handlers. It offers route patterns, variable constraints, HTTP method matching, and flexible callbacks, making it easy to build clean, maintainable routing layers for custom PHP applications.
Architecture fit — poor. Hoa\Router is a standalone, framework-agnostic route matcher. Laravel's router is a dispatch contract: Illuminate\Routing\Router owns route registration, the middleware pipeline, controller resolution, route model binding, named-route URL generation, signed URLs, and route caching. Hoa returns a matched rule and extracted variables — nothing else. Adopting it means either running two routers or rebuilding the dispatch layer around it. That is an impedance mismatch at the architecture level, not an API-shape problem.
Integration feasibility — technically possible, practically unattractive. There is no Laravel service provider, facade, config, or published integration pattern, and zero dependents on Packagist means no reference implementations to copy. Composer installation is likely fine, but the package is archived (last release 2017-01-14) and pulls abandoned Hoa transitive dependencies. A credible proof of concept — adapter, parity harness, dispatch shim — is multi-week work for a senior Laravel engineer.
Technical risk — high.
each(), and other deprecations).route(), signed URLs, route:cache, model binding, middleware — are lost or must be reimplemented.Key questions.
The package signals are consistent with this read: 28 stars, 0 dependents, archived, overall score ~1.05, and only a modest 16.82 opportunity score.
Stack fit — poor for a standard Laravel app. Hoa would sit outside the HTTP kernel, so you either bypass Laravel's router for selected paths or maintain parallel routing tables. It is a defensible fit only for non-Laravel CLI/HTTP microservices or a tightly scoped legacy bridge.
Migration path. If pursued, isolate behind an internal RouteMatcher contract with two implementations: Laravel native (default) and Hoa (opt-in per path prefix). Run Hoa in shadow mode against production traffic, comparing match results with Laravel's router, and gate any cutover on parity metrics. Hoa must never own URL generation, middleware, or controller dispatch.
Compatibility. Verify Composer resolution on the target PHP (8.1+), audit transitive Hoa dependencies for abandonment, run the upstream tests, and produce a rule-syntax compatibility matrix versus Laravel. Budget for a vendored, patched fork rather than a clean dependency.
Sequencing.
For most teams this sequence terminates at step 1, and that is the correct outcome. If the underlying need is framework-agnostic matching, Symfony Routing or FastRoute is the maintained path; if it is legacy DSL preservation, translate routes at build time.
Maintenance. Upstream is effectively unmaintained. Adoption means owning a fork indefinitely: PHP upgrades, dependency updates, test-suite modernization, and security patches. This is a recurring, unbudgeted cost with no vendor to escalate to.
Support. No active maintainers, no vendor, negligible community (28 stars, 0 dependents). Incident resolution is entirely internal, and knowledge will concentrate in one or two engineers — a real bus-factor risk.
Scaling. Matcher throughput is not the concern; regex-based matching is adequate at typical route counts. The scaling risk is operational: every new routing feature (constraints, domains, localization, caching) becomes bespoke engineering, and the route-cache story is unclear, which can hurt cold-start and deploy times at scale.
Failure modes.
route() and signed-URL generation where Hoa owns matching.Ramp-up. The public API is small, so surface-level ramp-up is days. The hidden work — dispatch, middleware bridging, URL generation, parity testing — is where the cost lives. Estimate 2–4 weeks to a credible spike and materially more to production parity, versus near-zero for staying on Laravel's router.
Recommendation. Do not adopt hoa/router in a Laravel application. The archived status, absence of dependents, and architectural mismatch outweigh any narrow matching benefit. If a specific legacy routing requirement exists, translate it at build time or wrap a maintained alternative; keep Hoa out of the critical path.
How can I help you explore Laravel packages today?