An open API service indexing awesome lists of open source software.

https://github.com/alfrcr/paginathing

a jQuery plugin to paginate your DOM easily.
https://github.com/alfrcr/paginathing

dom javascript jquery jquery-plugin paginate pagination

Last synced: 3 months ago
JSON representation

a jQuery plugin to paginate your DOM easily.

Awesome Lists containing this project

README

          

# Paginathing

#### Paginate Everything (support BootstrapCSS 5)

a dead-simple jQuery plugin for paginate your html elements. [DEMO](https://paginathing.netlify.app)

#### How does the plugin work?

Originally `paginathing.js` hide all your selector's children DOM. Then shows the DOM based on active page by using jQuery .show()

## Requirements

- jQuery

## Usage

Your html markup (example)

```html



List of item.




  • Your Item 1

  • Your Item 2

  • Your Item 3

  • Your Item 4

  • Your Item 5

  • Your Item 6


```

#### Include jQuery & paginathing first

```html

```

#### Initialize

```html

jQuery(document).ready(function ($) {
$(".list-group").paginathing({
perPage: 2,
containerClass: "panel-footer",
});
});

```

## Available Options

```js
{
// show item per page
perPage: 10,
// Limiting your pagination number.
// Value could be boolean or positive integer.
limitPagination: false,
// Enable previous and next button
prevNext: true,
// Enable first and last button
firstLast: true,
// Previous button text
prevText: '«',
// Next button text
nextText: '»',
// "First button" text
firstText: 'First',
// "Last button" text
lastText: 'Last',
// Extend default container class
containerClass: 'pagination-container',
// Extend default