vnphp / paginator-bundle
Useful KNP paginator extensions.
Installs: 217
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Forks: 0
pkg:composer/vnphp/paginator-bundle
Requires (Dev)
- phpunit/phpunit: ^5.1
This package is auto-updated.
Last update: 2025-10-14 21:33:02 UTC
README
Installation
composer require vnphp/paginator-bundle
You need to have git installed.
Usage
Add the bundle to your AppKernel.php:
<?php
$bundles = array(
new \Vnphp\PaginatorBundle\VnphpPaginatorBundle(),
);
Usage
<?php
if ($page > 1) {
$limit = 20;
$paginatorOffset = -1;
} else {
$limit = 19;
$paginatorOffset = 0;
}
$this->paginator->paginate($query, $page, $limit, [
'offset' => $paginatorOffset,
]);
