# angular-simpler-pagination

> The simplest possible pagination for angular apps

Latest version **1.1.4** (published 2016-12-22) · MIT license · 0 weekly downloads

## Install

```sh
npm install angular-simpler-pagination
pnpm add angular-simpler-pagination
yarn add angular-simpler-pagination
bun add angular-simpler-pagination
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.1.4 |
| Published | 2016-12-22 |
| First published | 2015-08-02 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Lior Wohl |
| Maintainers | liorwohl |
| Keywords | pagination, paginator, angular |

## Links

- npm: https://www.npmjs.com/package/angular-simpler-pagination
- Repository: https://github.com/liorwohl/angular-simpler-pagination
- Homepage: https://github.com/liorwohl/angular-simpler-pagination#readme
- Issues: https://github.com/liorwohl/angular-simpler-pagination/issues
- npm.io page: https://npm.io/package/angular-simpler-pagination

## Recent versions

- 1.1.4 (latest) — 2016-12-22
- 1.1.3 — 2016-11-27
- 1.1.2 — 2016-08-11
- 1.1.1 — 2016-02-24
- 1.1.0 — 2016-02-24
- 1.0.1 — 2016-02-09
- 1.0.0 — 2015-08-02

## README

# angular-simpler-pagination
Use this simple script if you want a simple client side only pagination (and sorting) for your Angular app.

# Install
npm install angular-simpler-pagination --save  
  
then add to your JS (if using browserify): require('angular-simpler-pagination'); 

add to your app code:  
angular.module('appName', ['angular-simpler-pagination'])

# Usage
order by: &lt;a table-sort="'yyy' for-id="'xxx'">Yyy&lt;/a> | &lt;a table-sort="['zzz','!yyy']" for-id="'xxx'">Zzz and then Yyy desc&lt;/a>  
items:  
&lt;ul>  
  &lt;li ng-repeat="item in someItemsArray | paginate:10:'xxx':'yyy'">  
    {{item}}  
  &lt;li>  
&lt;/ul>  
&lt;paginator for-id="'xxx'">&lt;/paginator>

'xxx' is the paginator ID, needed for when you have more then one paginator in the same page  
'yyy' or 'zzz' is the sorting column  
10 is the items per page

# Basic CSS
You need to style the paginator, after using a reset to remove default browser styling from UL LI tags, use something like:  
.pagination li {  
  display: inline-block;  
  padding: 5px 0;  
}  
.pagination .active {  
  font-weight: bold;  
}  
.orderByDesc {  
  ...  
}  
.orderByAsc {  
  ...  
}  
  
# Thanks to..
http://cacodaemon.de/index.php?id=50 for the ideas and the code I started with.

---
_Source: https://npm.io/package/angular-simpler-pagination · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
