Skip to content

large ng-repeat lists transition slowly to update view #3299

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

Closed
mbokil opened this issue Jan 26, 2017 · 2 comments
Closed

large ng-repeat lists transition slowly to update view #3299

mbokil opened this issue Jan 26, 2017 · 2 comments

Comments

@mbokil
Copy link

mbokil commented Jan 26, 2017

I grabbed the latest ui-router and angular 1.x from bower. I created a select list in angular using ng-repeat which is about 3K rows long. When switching route state there is a delay of 7 seconds on Chrome with a Macbook. Only fix I found was to delete the list child nodes by setting the parent container for the list to an empty string using innerHTML before switching state. This reduced the transition to about 1 sec.

        var clinicList = document.getElementById('clinicList');
        if (clinicList) document.getElementById('clinicList').innerHTML = '';
        $state.go('selectshiftlistview');
@vovopap
Copy link

vovopap commented Feb 20, 2017

I am having exactly the same issue. the transition from the 'heavy' state takes normal time on desktop browsers. but on iPad browsers (both safari and chrome) it takes about 15 seconds to transition from the state.
ui-router: v0.3.2
angular: v1.5.8

@christopherthielen
Copy link
Contributor

If this is ui-router's fault, I'd love to fix it. However, I need a minimal reproduction to determine if it's the router being slow, or just angular itself.

Please reproduce the behavior in a plunker:

I'm closing this because there isn't enough information to act on. Once a plunker is created, we can reopen and see if ui-router is at fault.

Note that there are some perf enhancements coming in rc.2 especially related to ui-sref and generating URLs. See #3361

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants