- Is sbsedv/paginator-bundle a Laravel package or a Symfony bundle?
- It is a Symfony bundle. It registers through the Symfony kernel and DI container, not a Laravel service provider, so it will not auto-discover in a Laravel application. Treat it as PHP-ecosystem adjacent rather than Laravel-fit, and confirm your target stack before adding it to composer.json.
- How do I install sbsedv/paginator-bundle in a Symfony application?
- Install it with Composer using composer require sbsedv/paginator-bundle, then enable the bundle in config/bundles.php for the environments you need. No additional migration is required for the 1.7.0 release because the change is constraint-only. After install, verify the resolved versions with composer show and composer why-not before relying on the new Symfony range.
- Can I use sbsedv/paginator-bundle in a Laravel app with LengthAwarePaginator?
- Not directly. The package resolves pages through Symfony request and container semantics, and its pagination model does not map cleanly onto Laravel's LengthAwarePaginator. You would have to own a bespoke adapter layer that upstream does not maintain. Decline that scope unless there is a documented requirement Laravel's native paginator cannot satisfy.
- What changed in version 1.7.0 of sbsedv/paginator-bundle?
- The single change widens the Symfony version constraint so Symfony 8 is permitted. There are no API changes, no deprecations, no behavioural changes and no new features. It is a compatibility-hygiene release rather than a capability release, so nothing in your code needs to move.
- Which Symfony versions does sbsedv/paginator-bundle support?
- The 1.7.0 constraint admits Symfony 8 alongside the previously supported majors, which you should confirm by reading the composer.json in the tagged release. A widened constraint is permission, not proof: check that the repository CI matrix actually runs against Symfony 8. Then run your own integration suite on Symfony 8 in a branch before promoting it to a supported combination.
- How do I configure page size and the current page?
- Page size and current-page resolution are configured through the bundle's service container integration rather than hard-coded in your controllers. You define the paginator service with your desired page size, and the current page is derived from the request handling you wire up. Keeping those values in configuration makes it easy to expose different page sizes per listing or search view.
- How do I expose total items and total pages to templates for navigation?
- The paginator exposes total item and total page metadata on the page-aware collection it returns. Pass that object to your Twig template and read the counts when rendering prev, next and numbered links. Because the metadata is computed once per collection, you avoid recounting rows inside the template layer.
- Can the paginator handle plain arrays as well as query results?
- Yes. The bundle is designed to convert arrays or query results into page-aware collections, so in-memory lists and database-backed result sets use the same interface. That consistency is useful for search results, API responses and other data-driven views. For Doctrine-backed sets, confirm that your adapter versions are compatible with the Symfony major you resolve.
- Is upgrading to v1.7.0 a breaking change for existing projects?
- No. The change is backwards-compatible by construction because it only expands a constraint, so existing pins to earlier 1.x releases continue to resolve and behave identically. Be aware that widening is silent: projects on a caret constraint inherit Symfony 8 eligibility on the next composer update. Pin deliberately instead of drifting into an untested combination.
- What are the alternatives to sbsedv/paginator-bundle, and is it well maintained?
- For Symfony, the established options are Pagerfanta with its adapters and KnpPaginatorBundle, both of which have broader adoption and larger contributor bases. This repository shows a low-traffic profile with single-author commits and low PR numbering, so factor bus factor into your durability assessment. If you are on Laravel, use the framework's built-in paginator rather than adopting a Symfony bundle plus a custom adapter.