Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Yalr Laravel Package

dentro/yalr

YALR (Yet Another Laravel Roles) is a lightweight roles and permissions package for Laravel. Assign roles to users, attach permissions to roles, and check abilities through simple methods, middleware, and Blade directives.

View on GitHub
Deep Wiki
Context7

Technical Evaluation

Architecture fit. dentro/yalr is a convention layer over Laravel's existing router: it lets you express routes as classes instead of entries in routes/web.php or routes/api.php. It does not replace the dispatcher, so middleware, route-model binding, form requests, and policies remain framework-native — assuming the package is a thin adapter. That makes it an application-layer pattern (like invokable controllers or spatie/laravel-route-attributes) rather than an infrastructure commitment. Architecturally cheap to say yes to; the risk is convention drift, not coupling.

Integration feasibility. Low. Typical shape is composer require dentro/yalr, register a service provider, publish a config file pointing at a discovery directory. That is hours, not weeks, and is reversible. The real feasibility question is not "can we install it" but "does it survive contact with route:cache, route:list, route() URL generation, and the Laravel 11+ bootstrap/app.php routing model."

Technical risk. High relative to the value delivered — but materially lower than the prior assessment, on one axis.

  • Maintenance signal improved. v1.6.0 bumps support for Laravel 13. The prior assessment flagged "no forcing function to keep up with Laravel majors" as a top risk; the maintainer has now demonstrated that forcing function once, inside a reasonable window. That is the single most credible positive signal this package has produced.
  • Adoption signal is still near zero. 8 stars, 0 dependents, no downstream bug reports. Nothing here has been hardened by other people's production traffic, and a Laravel 13 compatibility bump does not change that.
  • Boot-time discovery. Directory scanning at application boot is a classic silent performance regression if it doesn't participate in route:cache. Unchanged by this release and still must be measured, not assumed.
  • Semver hygiene question (new). "Bump support for Laravel 13" frequently means swap support, not add support: maintainers drop Laravel 10/11 constraints because the CI matrix becomes untenable. If v1.6.0 dropped older majors inside a minor version bump, that is a breaking change published as non-breaking, and it is a leading indicator of how this maintainer will treat downstream consumers. Diff composer.json between v1.5.0 and v1.6.0 before anything else.
  • Claim vs. evidence. The release notes are a single line. There is no statement about the CI matrix, the route-cache round-trip on 13, Octane, or routing-internal changes in 13 that might affect a discovery layer. Support was declared; it was not demonstrated in the notes.
  • Metadata anomaly. The release date (2026-03-19) and the high abstract score (9.79) against a low opportunity score (22.42) suggest static-analysis scoring rather than real-world traction. A version bump does not resolve that.

Key questions to answer before any code is written:

  1. Does it coexist with routes/web.php, or does it take over route registration? Can I run both in one app?
  2. Does php artisan route:cache work, and does the cached output match the uncached output byte-for-byte?
  3. Are named routes, route groups, prefixes, domains, and ->name() preserved? Does route('x') still resolve?
  4. How are middleware, middleware groups, and withoutMiddleware expressed — per class, per method, via attributes, or config?
  5. Route-model binding, soft deletes, and custom resolution: supported or bypassed?
  6. What are the composer.json constraints as of v1.6.0 — did Laravel 10/11 support get dropped to make room for 13? Is there a CI matrix proving all currently claimed majors, including 13?
  7. Octane and long-running worker compatibility: are routes registered once at boot, or per request?
  8. Test coverage and code quality — is there a test suite I can read in an afternoon? Did the v1.6.0 diff touch tests or only composer.json?
  9. What is the exit path if the package dies? Is routing config declarative enough to mechanically convert back to Route:: calls?

Integration Approach

Stack fit. Unchanged. Treat this as a developer-ergonomics choice inside a single bounded context, not a platform decision. It fits a team that already thinks in "one class per endpoint" (action/handler style) and is comfortable with attribute-driven configuration. It fits poorly on a team that has standardized on resource controllers and Route::resource, because you will end up with two idioms in one codebase and reviewers will have to context-switch.

Migration path. Do not migrate. Coexist.

  • Leave routes/web.php and routes/api.php untouched.
  • Pick one new, self-contained surface — a new API module, a bounded context, or an internal admin area — and express only that surface as route classes.
  • Verify in a branch that both route sets appear correctly in route:list and that there are no collisions or ordering surprises.
  • Ship behind a config flag so revert is a one-line change, not a revert commit.

Compatibility checks (blocking gates).

  • New, first gate: diff v1.5.0 → v1.6.0. Confirm whether Laravel 10/11/12 support was retained, and whether the version bump should have been a major. If older majors were silently dropped, treat every future minor release as potentially breaking and pin hard.
  • Pin exact Laravel, PHP, and package versions; confirm the v1.6.0 constraints cover your current major, not just 13.
  • Run the full CI matrix (PHP × Laravel) with the package installed, even on code paths that don't use it. Include your production Laravel version explicitly — a package that now "supports 13" is not the same as one that is tested on your version.
  • Assert route:cache / route:clear round-trips cleanly, and diff route:list before and after.
  • Smoke-test under Octane if you use it.
  • Benchmark boot time with and without the package on a realistic route count.

Sequencing.

  1. Constraint audit (1 hour). Read the v1.5.0 → v1.6.0 composer.json diff. This is cheap and it either clears the maintenance concern or escalates it.
  2. Spike (1 day). Install on a throwaway branch, define 5–10 route classes covering middleware, prefixes, named routes, and one route-model-bound resource. Answer the key questions above. If you are on Laravel 13, this is now a viable spike target; if you are on 10/11, verify you are not on a deprecated branch of the package.
  3. PoC (3–5 days). Apply to one real module. Measure boot time, route:cache behavior, and developer time-to-first-endpoint versus an invokable controller.
  4. Side-by-side DX comparison. Against Laravel's native invokable controllers and, more importantly, against spatie/laravel-route-attributes — the incumbent in this niche with real adoption. Notably, the incumbent also supports current Laravel majors, so v1.6.0 closes the one gap where YALR had a defensible argument. That strengthens the default-to-incumbent position rather than weakening it.
  5. Go/no-go with a written exit plan. If yes: internal style guide, one worked example, and a named owner. If no: document why, so the question doesn't get re-litigated next quarter.

Operational Impact

Maintenance. Improved but not resolved. The v1.6.0 release is the first evidence that the maintainer tracks Laravel majors, which was the single biggest "package quietly dies" risk in the prior assessment. Keep the pin exact anyway, and keep the 12-month vendor/fork budget — one release is a data point, not a track record. Add the constraint diff to the quarterly upstream review; the question to ask each cycle is no longer "is anyone home?" but "did the last release drop a major without a major version bump?"

Support. MIT, community only, no vendor, no SLA, no security disclosure process visible. Unchanged. Acceptable for a dev-time convenience layer that fails loudly at boot; not acceptable if the package ends up on the request path in a way that can fail silently at runtime. Keep the blast radius to registration-time behavior.

Scaling.

  • Boot time is the primary scaling concern. Directory scanning is O(number of route classes) at every process start. With route caching this is amortized to zero; without it, it compounds with worker count and deploy frequency.
  • Route count also affects route:list and cache build time, but at realistic scale (hundreds of routes) this is noise.
  • Cognitive scaling is the underrated cost: every new engineer must learn a second routing idiom, and grep-for-URL becomes grep-for-class-name. Unchanged, and this is now the strongest remaining argument against adoption given the maintenance signal has improved.

Failure modes to monitor.

  • Dropped-major silent break (new, highest priority). A future minor release bumping framework support by removing an older major, discovered only when composer update fails or, worse, when it succeeds and behavior shifts.
  • Route cache silently going stale or diverging from the uncached route table — specifically on Laravel 13, where the package's compatibility claim is one release old and thinly documented.
  • Silent route shadowing between class-based routes and legacy Route:: entries — ordering is registration-order dependent and easy to get wrong.
  • Middleware ordering shifts that change auth or throttling behavior without any code diff.
  • Breakage on a Laravel major upgrade with no upstream release. Likelihood reduced as of v1.6.0; impact and detection time unchanged.
  • Discoverability failure: 404 in staging because a route class sits outside the configured discovery path.
  • Octane state leakage if route registration is not strictly boot-time.

Ramp-up. One to two days per engineer to become productive, plus the cost of writing the internal guide that doesn't exist yet. Unchanged by this release. Mitigate with a single reference module, a documented "when to use route classes vs. controllers" rule, and a reviewer checklist. The honest TPM recommendation is unchanged but better informed: run the spike, benchmark it against spatie/laravel-route-attributes, and default to the incumbent. v1.6.0 removes the "it will die on the next Laravel major" objection — which was real — but it does not create a reason to prefer YALR over the incumbent, because the incumbent now matches it on framework coverage and beats it on adoption by two orders of magnitude.

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
uni-method/symfony-lib
tacticmedia/scim-server-bundle
neika-ai/symfony-bundle
mattleads/agent-publishing-bundle
glavweb/framework-bundle
glavweb/extra-bundle
glavweb/api-bundle
glavweb/admin-bundle
adachsoft/api-version-bundle
elsayed85/laravel-api-exceptions
ouhssini/laravel-demo-mode
daworks/ncloud-outbound-mailer-driver
gp247/cms
ignibyte/aic-gates
nexa-merchant/blog
novasa/laravel-language-center
opencage/geocode
adolfoholzer/parameters
livenetworks/ln-starter
cgv/localized-resource