ionic-framework: bug: Several collection-repeat on the same template

Type: <span ionic-type>bug</span>

Platform: <span ionic-platform>android</span> <span ionic-platform-version>4.4</span> <span ionic-webview>webview</span>

<span ionic-description>I have a ion-list with several ion-item like that:

<ion-list>
        <ion-item class="item-divider">
            Pending
        </ion-item>
        <ion-item
                collection-repeat="pending in pendings">
            <h2>{{pending}}</h2>
        </ion-item>
        <ion-item class="item-divider">
            Recent
        </ion-item>
        <ion-item class="item-text-wrap"
                  collection-repeat="recent in recents">
            <h2">{{recent}}</h2>
        </ion-item>
</ion-list>

The items are not displayed and I get

Uncaught RangeError: Maximum call stack size exceeded
RepeatController.scrollView.__callback

The error is in the following code:

    scrollView.__callback = function(transformLeft, transformTop, zoom, wasResize) {
      var scrollValue = view.getScrollValue();
      if (renderStartIndex === -1 ||
          scrollValue + view.scrollPrimarySize > renderAfterBoundary ||
          scrollValue < renderBeforeBoundary) {
        render();
      }
   ====>   scrollView.__$callback(transformLeft, transformTop, zoom, wasResize);
    };

Please note that this error occurs with JS Scrolling. If I have only one collection-repeat instead of 2, it’s OK.

I also tried one collection-repeat and one ng-repeat with native scrolling and the collection-repeat does not display all the items.</span>

<span is-issue-template></span>

About this issue

  • Original URL
  • State: closed
  • Created 9 years ago
  • Comments: 20 (3 by maintainers)

Most upvoted comments

+1 same issue here.

Cordova CLI: 6.1.1 Gulp version: CLI version 3.9.0 Gulp local: Local version 3.9.0 Ionic Version: 1.3.0 Ionic CLI Version: 1.7.14 Ionic App Lib Version: 0.7.0 OS: Distributor ID: LinuxMint Description: Linux Mint 17.2 Rafaela Node Version: v0.12.14