perf: investigate optimization for updateViews() in repeat #6025
Labels
area:fast-element
Pertains to fast-element
improvement
A non-feature-adding improvement
status:in-progress
Work is in progress
Milestone
Following some investigation around repeat performance, we looked at a couple of scenarios:
updateViews() in RepeatBehavior class is triggered when array is updated (.splice() , .push()),
According to findings:
"In the way, it will try to apply splice on views, and try to reuse the removed views to bind with new data, insert them to new locations. It looks better than refreshAllViews since it only applies bindView to those updated items,
However, updateViews will always invoke insertBefore, even if it’s an in-place update, like array.splice(0, 1, array[0])."
Some possible points of investigation and benchmarks to write are:
The text was updated successfully, but these errors were encountered: