VirtualScroll does not allow array to be cleared

I’m using a VirtualScroll to control an ion-list and an ion-searchbar to be able to filter the contents. Everything works as expected, except when the filter returns an empty array. When this happens the VirtualScroll does not update the status to reflect on this new state.

<ion-header>
  <ion-navbar>
    <ion-title>StopList</ion-title>
  </ion-navbar>
</ion-header>

<ion-content>
  <ion-searchbar type="text" (input)="filterItems($event, searchKey)"></ion-searchbar>
  <ion-list [virtualScroll]="items">
    <ion-item *virtualItem="let item">
      <h2 >{{item.name}}</h2>
      <p>{{item.description}}</p>
    </ion-item>
  </ion-list>
</ion-content>
1 Like

Yup, experiencing the same issue. Not working in Beta 10.

I have same issue with 2.0.0-rc.2

The problem still occurs with 2.0.0-rc.2, had to revert to ngFor