Collection-repeat in tabs and rememberScrollPosition


If I use only the ion-content without tabs the scroll position it’s ok… when I go back the app keeps the scroll position.

<ion-content class="has-header">
  <feed-list tab="templates/partials/latest.html"></feed-list>

If I wrap the ion-content inside a tab like that:

<ion-tabs class="tabs-positive tabs-icon-only">

  <ion-tab title="Latest" icon="ion-home">
    <ion-content class="has-header">
      <feed-list tab="templates/partials/latest.html"></feed-list>

  <ion-tab title="Friends" icon="ion-home">
    <!-- other tab content -->


Inside the templates/partials/latest.html there is my collection-repeat.

The scroll position is lost if you change state or if you change tab!

Any thoughts?



Good catch @zelphir, I’ll open an issue for this!


After the commit 9b601b55 it remembers the scroll position, but… It’s slow if the lists are long (and contain images)… There is a lag, when you go back or change tab… it starts from the top and then scroll to the position… it’s not very nice to see this effect!

Maybe add a delay and render the ion-content only when the scroll is at the right position.

The lag is only visible on real devices, not in the browser or ios emulator.