Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v1.0.0-beta.13-nightly-852: collectionRepeat Performance Issue Caused by the Wrong Size Calculation #2677

Closed
dreamershl opened this issue Dec 6, 2014 · 1 comment

Comments

@dreamershl
Copy link

This will defeat the whole performance improvement. The issue is triggered by the event "resize"

  1. Switch to another view from a view with collectionRepeat. The new view will display a modal. Then the following code will be called
modalEl.addClass('ng-enter-active');
ionic.trigger('resize');
  1. Because of the event registration "ionic.on('resize', rerenderOnResize, window)" in collectionRepeat the following code will be called in the condition (secondaryScrollSize = 0)

    collectionRepeatManager.resize();

  2. Because of the secondaryScrollSize=0, the function "calculateSize" will believe all the items should be rendered as first item.

The final result is collectionRepeat will render every item in the datasource, which normally will be thousands. This will cause the serious performance issue.

@ajoslin
Copy link
Contributor

ajoslin commented Feb 5, 2015

Fixed, thanks for the investigation.

@ionitron-bot ionitron-bot bot locked and limited conversation to collaborators Sep 6, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants