Enable option for gradual expanding of large children arrays#133
Open
ssteffl wants to merge 5 commits intowix-incubator:masterfrom
ssteffl:master
Open
Enable option for gradual expanding of large children arrays#133ssteffl wants to merge 5 commits intowix-incubator:masterfrom ssteffl:master
ssteffl wants to merge 5 commits intowix-incubator:masterfrom
ssteffl:master
Conversation
|
Bravo on this pull request!! Just stumbled on it today as we've been having lots of problems loading large trees. After some trial and error with the childrenTimeInterval and childrenLimitInterval settings, we have trees loading steadily, providing visual cue to the user while still remaining responsive enough if the user wishes to do something else while the tree finishes loading. Good stuff! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
angular-tree-control has good performance on large data-sets partially because it onlyrenders children when the parent is toggled open. But it is very slow when a parent has many children (I have on the order of 500 in some instances). On top of that, when I use ng-include for each of the children labels, it causes the browser to freeze for >5 seconds while angular is compiling all 500 of the children nodes
This commit adds a 3 extra options that allow for better rendering. They are turned off by default so original behavior remains the default. The 3 options are:
For Example, if these were the option values:
when a parent node is expanded, it will append 10 children nodes every 10 ms. This will not freeze the screen, and allow the user to still interact with stuff while the children are being added.
I call it enableIntervalToggle because it adds children nodes on an interval when the parent is toggled open.