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

Pagination Laravel Package

mrshanebarron/pagination

A Laravel pagination package that provides helpers for creating, rendering, and customizing paginated result sets and navigation links, simplifying multi-page data display in Blade templates and API responses.

View on GitHub
Deep Wiki
Context7

A lightweight pagination package for Laravel that simplifies splitting large datasets into manageable pages. It integrates cleanly with Laravel’s query builder and Eloquent, providing a straightforward API for generating paginated results and rendering navigation links.

  • Seamless Laravel and Eloquent integration
  • Customizable pagination views and markup
  • Preserves query strings across page links
  • Simple configuration for per-page limits
  • Blade-friendly rendering for rapid setup
Frequently asked questions about Pagination
How do I install mrshanebarron/pagination in a Laravel application?
Install it with Composer by running composer require mrshanebarron/pagination from the root of your Laravel project. Laravel's package auto-discovery should register the service provider automatically, so manual edits to config/app.php are usually unnecessary. After installation, check the repository README for any publish or configuration steps the package expects.
Which Laravel and PHP versions does this pagination package support?
The exact supported range is defined in the package's composer.json require constraints, so check that file or the README before installing. Running composer require will surface a conflict immediately if your Laravel or PHP version is out of range. This matters most on older LTS releases or the newest major Laravel version.
How do I customize the pagination links and Blade views?
Laravel renders pagination links through Blade views, and UI component packages normally let you publish those templates into your own resources/views directory. Run the vendor:publish command described in the README and use the matching provider tag. Once published, your local copies override the package versions, so you can restyle the markup freely.
Can I paginate an array or collection instead of an Eloquent query?
Laravel's built-in paginator can wrap plain arrays and collections using LengthAwarePaginator and Paginator::resolveCurrentPage. Whether this package accepts non-Eloquent input depends on its API, so verify in the README or source before relying on it. For simple in-memory data, Laravel's native collection pagination may already be sufficient.
How do I publish the package configuration file?
If the package ships a config file, it will be publishable with php artisan vendor:publish and the appropriate provider tag. The README is the authoritative source for the exact tag name. Always edit the published file in your config directory rather than modifying anything inside vendor, since vendor changes are lost on update.
Does it work with Tailwind CSS or Bootstrap pagination styles?
Laravel ships Tailwind-based pagination views by default and lets you switch with Paginator::useBootstrapFive or Paginator::useBootstrapFour. If this package relies on Laravel's default views, those same methods apply. If it provides custom templates, check the README for the supported CSS framework and any override instructions.
How do I test pagination output in my Laravel test suite?
Use feature tests with assertions such as assertSee on rendered links, or inspect the JSON structure when the paginator is returned from a controller. Make sure the package service provider and any views are loaded in the test environment. Useful checks include the current page, per-page value, total count, and the presence of previous and next links.
Can I use this package for API responses and JSON pagination?
Laravel's paginator returns a JSON payload containing data, links, and meta when returned from a controller, and most pagination packages preserve that format. Confirm in the README whether this package alters or extends the standard resource structure. For a stable public contract, wrap the paginator in API Resource classes so the shape stays consistent.
What are the alternatives to mrshanebarron/pagination?
Laravel already includes a complete pagination system through Eloquent, the query builder, and the Paginator facade, which covers most requirements without extra dependencies. This package is most valuable when you want ready-made UI components and quicker setup. Compare its feature list against Laravel's built-in paginator before adding a dependency to your project.
Is this package actively maintained and safe for production use?
Before adopting any small package, review the repository's recent commits, tagged releases, and open issues to gauge maintenance activity. Also confirm the composer.json constraints match your PHP and Laravel versions and that the license suits your project. If activity looks stale, Laravel's built-in pagination remains a dependable fallback.
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.
robertmarney/lara-hierarchial-collections
simonschaufi/rule-doc-generator
emissaoja/emissaoja
blackbricksoftware/gravityforms-civicrm-form-processor
al-rahabi/fancy-crud
jinas/dhivatar-component
mltstephane/laravel-quality
bernskiold/laravel-talentlms
bernskioldmedia/laravel-form-architect
youbar/easy-crud
c-point-labs/laravel-hostyourai
dbravoan/dbcms-admin-theme-dbcms
dbravoan/dbcms-theme-db-cyber
dbravoan/dbcms-blocks-basic
dbravoan/dbcms-module-content-audit
dbravoan/dbcms-module-ai-assistant
paygate-to/paygate-php
padosoft/askmydocs-connector-base
defstudio/supercharged-carbon
bernskioldmedia/laravel-matomo