roquie/laravel-perpage-resolver
A lightweight Laravel package that resolves per-page values for pagination from incoming requests. It centralizes defaults, allowed limits, and validation so every endpoint returns consistent page sizes without hardcoding request checks or scattering pagination logic.
The 2.0.0 notes are strictly a compatibility announcement — they tell you whether you can install it, not what it does. Treat the upgrade as a dependency-and-environment task before it is a code task.
8.0.*, not >=8.0) and Laravel ^8 or ^9. If you are on PHP 8.1+ or Laravel 10+, this release is not installable for you — see Gotchas.src/ tree between the 1.* tag you run and 2.0.0, and check the repo's UPGRADE.md/CHANGELOG.md if present.2.0.0 on a throwaway branch, run composer why-not if resolution fails, and let your existing test suite tell you what broke.Where to look first in the codebase: the service provider (what it binds and publishes), the config file (keys are the most common silent BC break), and any migration/table the package owns.
Isolate the package behind your own boundary. Because 2.0.0 is a hard BC break with no published migration guide, wrap the package's public surface in a thin application-level class or interface. When 3.x lands, or when you need to fork it for a newer Laravel, you change one class instead of grepping call sites. This is the single highest-value pattern for a package with this maintenance posture.
Constraint pinning in composer.json. Do not use ^2.0 loosely in a project you plan to keep on Laravel 8/9. Pin "vendor/package": "2.0.*" and commit composer.lock. The notes say the illuminate/database bump was for a security reason, which implies the maintainer ships narrow, security-driven patches — you want those, but you do not want surprise minors.
Config-driven setup. In a Laravel package upgrade the usual break points are: published config file keys, service-provider aliases, facade accessors, and default connection/table names. After upgrading, php artisan vendor:publish --force into a scratch directory and diff the new config against your published copy rather than overwriting it.
Composer-level compatibility check before code changes. composer update vendor/package --with-all-dependencies --dry-run is your fastest signal. If it reports a conflict on illuminate/database, the package's own constraints are inconsistent (see Gotchas) and you should stop and evaluate rather than force it with --ignore-platform-reqs.
Test against the constraint boundary, not your local machine. Your local PHP may be 8.2 while CI needs 8.0. Add a matrix entry for php: 8.0 and laravel: 8.*, 9.* so the package's supported envelope is actually exercised. Anything you rely on that only works because your environment is newer is a latent CI failure.
Upgrade in one PR, with the lock file and the code change together. Splitting "bump composer constraint" from "fix broken calls" produces a red main branch between the two commits and makes git bisect useless when something regresses.
illuminate/database ^8 + Laravel ^9 combination looks internally inconsistent. Laravel 9 ships illuminate/database ^9; a hard ^8 requirement cannot be satisfied alongside it unless the package uses an || constraint, a separate branch, or relies on replace/alias behaviour. Verify with composer why-not illuminate/database 9.* before assuming 2.0.0 actually installs on Laravel 9. This is exactly the kind of thing release notes get wrong.composer.json.config/your-package.php against the vendor copy.composer why vendor/package, composer why-not vendor/package 2.0.0, and composer show --tree will explain a failed resolution in seconds. --ignore-platform-reqs hides PHP/Laravel mismatches and converts an install-time error into a runtime one — avoid it.illuminate/database pinned at ^8 for a security fix and no support for Laravel 10+, a maintained fork that widens the constraints is often cheaper than staying pinned — especially if the package is load-bearing rather than peripheral.How can I help you explore Laravel packages today?