Answers for "How to implement Bootstrap 4 for Angular 2 ngb-pagination"

-3

How to implement Bootstrap 4 for Angular 2 ngb-pagination

export class HomeComponent implements OnInit {


currentPage = 1;
itemsPerPage = 5;
pageSize: number;

constructor() { }

  public onPageChange(pageNum: number): void {
    this.pageSize = this.itemsPerPage*(pageNum - 1);
  }
  
  public changePagesize(num: number): void {
  this.itemsPerPage = this.pageSize + num;
}

}
Posted by: Guest on May-26-2020

Code answers related to "TypeScript"

Browse Popular Code Answers by Language