# gavant-pagination

> The default blueprint for ember-cli addons.

Latest version **0.1.2** (published 2019-04-04) · MIT license · 0 weekly downloads

## Install

```sh
npm install gavant-pagination
pnpm add gavant-pagination
yarn add gavant-pagination
bun add gavant-pagination
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 0.1.2 |
| Published | 2019-04-04 |
| First published | 2019-04-02 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | 6.* \|\| 8.* \|\| >= 10.* |
| Dependencies | 6 |
| Unpacked size | 38.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Maintainers | bakerac4 |
| Keywords | ember-addon |

## Links

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

## Dependencies (6)

- [moment](https://npm.io/package/moment.md) ^2.24.0
- [ember-cli-babel](https://npm.io/package/ember-cli-babel.md) 7.6.0
- [ember-decorators](https://npm.io/package/ember-decorators.md) 5.1.4
- [ember-cli-typescript](https://npm.io/package/ember-cli-typescript.md) ^2.0.0
- [ember-cli-moment-shim](https://npm.io/package/ember-cli-moment-shim.md) ^3.7.1
- [@ember-decorators/babel-transforms](https://npm.io/package/@ember-decorators/babel-transforms.md) ^2.1.2

## Recent versions

- 0.1.2 (latest) — 2019-04-04
- 0.1.1 — 2019-04-04
- 0.1.0 — 2019-04-04
- 0.0.7 — 2019-04-03
- 0.0.6 — 2019-04-03
- 0.0.5 — 2019-04-03
- 0.0.4 — 2019-04-03
- 0.0.3 — 2019-04-03
- 0.0.2 — 2019-04-03
- 0.0.1 — 2019-04-03
- 0.0.0 — 2019-04-02

## README

gavant-pagination
==============================================================================

DISCLAIMER: This addon is not actively maintained for public use. Pull requests are welcome, but we do not guarantee responses to bug submissions or feature requests, so use at your own risk.

Compatibility
------------------------------------------------------------------------------

* Ember.js v2.18 or above
* Ember CLI v2.13 or above


Installation
------------------------------------------------------------------------------

```
ember install gavant-pagination
```


Usage
------------------------------------------------------------------------------

There are two ways to use this addon.

For classic classes, you use the mixin.

```
import Route from '@ember/routing/route';
import RoutePagination from 'gavant-pagination/mixins/route-pagination';

export default Route.extend(RoutePagination, {
    model() {
        const params = this.getControllerParams();
        return get(this, 'store').query('account', params);
    }
});
```

For Native classes, you use the "decorator".
```
import Route from '@ember/routing/route';
import RoutePagination from 'gavant-pagination/decorators/route-pagination';

export default class Accounts extends RoutePagination(Route) {
    model() {
        const params = this.getControllerParams();
        return this.store.query('account', params);
    }
}
```

Technically speaking you can actually use the route-pagination as a decorator..
```
import Route from '@ember/routing/route';
import RoutePagination from 'gavant-pagination/decorators/route-pagination';

@RoutePagination
export default class Accounts extends Route {
    model() {
        const params = this.getControllerParams();
        return this.store.query('account', params);
    }
}
```
but the main issue with that is RoutePagination will be the extend the `Accounts` Route, and generally you want the order of that to be reversed.

Contributing
------------------------------------------------------------------------------

See the [Contributing](CONTRIBUTING.md) guide for details.


License
------------------------------------------------------------------------------

This project is licensed under the [MIT License](LICENSE.md).

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