Display range records id from list order


I’m trying to find proper way to display limited range of records from search results list on .html page:

    <ion-list no-lines>
      <ion-item-divider *ngFor="let res of search" class="ion-card">
        <div> ID: {{res.ID}} </div>
        <div> User: {{res.user}} </div>

With possibility to display next or previous two IDs range from list order by increment/decrement counter for example.

If private search: any[] = []; contains records 12, 36, 69, 72, 90 which is a json strings in my case, with load I want display only first two records:

ID: 12
User: 78623786236784239678
ID: 36
User: 31556854673457367356

click on next button, second:

ID: 69
User: 45634564567886767777
ID: 72
User: 34578566565565533222

last one should be:

ID: 90
User: 53545645444336700458


maybe you shoud bind to an array that holds only the amount of data you need. With button click change content of array.

Best regards, anna-liebt


@anna_liebt Thank you