How views discover nodes, synchronize state, and batch updates efficiently.
The framework creates views automatically when a node needs to be displayed:
nodeViewClass().NodeClassNameView or NodeClassNameTile.clone() and associates it via setNode().SvNodeView.newSubviewForSubnode(node)
├── Determine view class
├── Create instance via clone()
└── Associate via setNode()When a node property marked with setSyncsToView(true) changes:
didUpdateSlot() fires.onUpdatedNode notification is posted.syncFromNode() via SvSyncScheduler at priority 2.When the user interacts with a view:
View-to-model syncs run at priority 0 (higher than model-to-view), ensuring user edits are applied before any reactive updates.
SvSyncScheduler is central to performance:
// Multiple updates, single sync cycle
this.scheduleSyncToView();
this.otherProperty().scheduleSyncToView();
// Both handled in one passwillAddSubview(subview) — Before adding a child viewwillRemoveSubview(subview) — Before removing a child viewwillRemove() — Before this view is removed from its parentonVisibility() — Element becomes visible (via IntersectionObserver)didChangeNode() — The node reference changedIntersectionObserver integration means off-screen views can skip expensive updates.