Skip to content

perf(sdui): cache visible row list and eliminate rows.any linear scan in SduiTreeBuilder - #1405

Merged
ZhuchkaTriplesix merged 1 commit into
devfrom
issue/1359-cache-sdui-tree-visible-rows
Oct 10, 2026
Merged

ZhuchkaTriplesix merged 1 commit into
devfrom
issue/1359-cache-sdui-tree-visible-rows

Conversation

@ZhuchkaTriplesix

Copy link
Copy Markdown
Member

Closes #1359

Summary

  1. Caches flattened visible rows in _cachedVisibleRows in SduiTreeBuilderState, invalidating only when schema, loaded nodes, expanded nodes, or errors change.
  2. Replaces rows.any((r) => r.isError) in itemExtent with _expandErrors.isNotEmpty, eliminating the linear list scan on every build.
  3. Added unit tests verifying row list identity caching on selection/rebuilds and (1)$ itemExtent resolution.

@ZhuchkaTriplesix
ZhuchkaTriplesix changed the base branch from main to dev October 10, 2026 20:58
@github-actions github-actions Bot added frontend Theme parser epic label: frontend performance Theme parser epic label: performance P2 Medium priority / Parity & Refactoring labels Oct 10, 2026
@ZhuchkaTriplesix
ZhuchkaTriplesix merged commit fabac2c into dev Oct 10, 2026
1 check passed
@ZhuchkaTriplesix
ZhuchkaTriplesix deleted the issue/1359-cache-sdui-tree-visible-rows branch October 11, 2026 15:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

frontend Theme parser epic label: frontend P2 Medium priority / Parity & Refactoring performance Theme parser epic label: performance

Projects

None yet

Development

Successfully merging this pull request may close these issues.

perf(sdui): cache visible row list and eliminate rows.any linear scan in SduiTreeBuilder.build()

1 participant