<ion-header>

  <ion-toolbar>
    <ion-title>Infinite Scroll</ion-title>
  </ion-toolbar>

</ion-header>


<ion-content>

  <ion-infinite-scroll (ionInfinite)="doInfinite($event)" position="top" [enabled]="enabled">
    <ion-infinite-scroll-content>
    </ion-infinite-scroll-content>
  </ion-infinite-scroll>

  <ion-list>
    <button ion-item (click)="goToPage2()" *ngFor="let item of items">
      {{ item }}
    </button>
  </ion-list>

  <p>
    InfiniteScroll is enabled: {{enabled}}
  </p>

  <button ion-button (click)="toggleInfiniteScroll()" block>
    Toggle InfiniteScroll Enabled
  </button>

</ion-content>
