Laravel Vue Pagination
A Vue.js pagination component for Laravel paginators that works with Bootstrap.
Requirements
Install
npm install laravel-vue-pagination// oryarn add laravel-vue-pagination
Usage
Register the component:
Vue;
Use the component:
Vue;
API
Props
Name | Type | Description |
---|---|---|
data |
Object | An object containing the structure of a Laravel paginator response. See below for default value. |
limit |
Number | (optional) Limit of pages to be rendered. Default 0 (unlimited links) -1 will hide numeric pages and leave only arrow navigation. 3 will show 3 previous and 3 next numeric pages from current page. |
current_page: 1 data: from: 1 last_page: 1 next_page_url: null per_page: 10 prev_page_url: null to: 1 total: 0
Events
Name | Description |
---|---|
pagination-change-page |
Triggered when a user changes page. Passes the new page index as a parameter. |
Credits
Laravel Vue Pagination was created by Gilbert Pellegrom from Dev7studios. Released under the MIT license.