knplabs/knp-components
Knp Components is a PHP component library from KnpLabs. It currently includes the Pager component for building flexible, “fancy” pagination and paging adapters. PHPUnit 10/11 supported; install with Composer and run the test suite via composer test.
ArgumentAccess with the knp_pager.items event by @mpdude in https://github.com/KnpLabs/knp-components/pull/343Full Changelog: https://github.com/KnpLabs/knp-components/compare/v5.1.0...v5.2.0
$options in knp_pager.before event by @mpdude in https://github.com/KnpLabs/knp-components/pull/342Full Changelog: https://github.com/KnpLabs/knp-components/compare/v5.0.0...v5.1.0
This is a major release, since a BC was introduced: the DBALQueryBuilderSubscriber now requires an instance of DBAL connection to be injected, otherwise it was impossible to make it work with DBAL version 4. Consequently, the BeforeEvent now accepts a third optional parameter: the connection mentioned above. If you don't pass the connection, the DBAL pagination won't be enabled.
If you use this library with Symfony (so, with the KnpPaginatorBundle), everything will be done for you.
Full Changelog: https://github.com/KnpLabs/knp-components/compare/v4.4.0...v5.0.0
Full Changelog: https://github.com/KnpLabs/knp-components/compare/v4.3.1...v4.4.0
Full Changelog: https://github.com/KnpLabs/knp-components/compare/v4.3.0...v4.3.1
Full Changelog: https://github.com/KnpLabs/knp-components/compare/v4.2.0...v4.3.0
Full Changelog: https://github.com/KnpLabs/knp-components/compare/v4.1.0...v4.2.0
Full Changelog: https://github.com/KnpLabs/knp-components/compare/v4.0.1...v4.1.0
Paginator constructor now accepts as second argument an instance of ArgumentAccessInterface, instead of a RequestStack. So you can now paginate outside the web context
Add compatibility with Symfony 6
This release add compatibility with doctrine/dbal 3 and drop compatibility with doctrine/dbal < 2.10
sortFieldWhitelist and filterFieldWhitelist options (use sortFieldAllowList and filterFieldAllowList instead)See #176
Thanks you @ostrolucky @garak @felds
Thanks you @cjchamado @Wolframcheg @dave-newson @ostrolucky @Soullivaneuh
How can I help you explore Laravel packages today?