de-paginator
TypeScript icon, indicating that this package has built-in type declarations

0.0.2 • Public • Published

PaginatorLib

Instllation :

npm i de-paginator

Import Module:

In app.module.ts:

import {DePaginatorModule} from 'de-paginator';

...

imports: [
  ...,
  DePaginatorModule
],

Example Usage :

First run

in app.component.html

<lib-de-paginator
  [currentPage]="page"
  [limitPerPage]="limit"
  [total]="total"
  (changePage)="pageSelect($event)"
></lib-de-paginator> 

in app.component.ts

import { Component } from '@angular/core';

@Component({
  selector: 'app-root',
  templateUrl: './app.component.html',
  styleUrls: ['./app.component.scss']
})
export class AppComponent {
  title = 'paginator-lib';
  total : Number = 151;
  limit : Number = 10;
  page : Number = 1;
  selectedPage ;
  pageSelect(e){
    alert('selected page is:' ,e);
    this.selectedPage =e;
  }
}

Readme

Keywords

none

Package Sidebar

Install

npm i de-paginator

Weekly Downloads

4

Version

0.0.2

License

none

Unpacked Size

65.1 kB

Total Files

21

Last publish

Collaborators

  • deep1144