LearnNewsExamplesServices
Frontmatter
id8873
titleRefactor: Standardize VNodeUtil and VDomUtil getChildIds to include components
stateOpen
labels
airefactoringcore
assignees[]
createdAtJan 24, 2026, 12:23 AM
updatedAtJan 24, 2026, 12:23 AM
githubUrlhttps://github.com/neomjs/neo/issues/8873
authortobiu
commentsCount0
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]

Refactor: Standardize VNodeUtil and VDomUtil getChildIds to include components

Openairefactoringcore
tobiu
tobiu commented on Jan 24, 2026, 12:23 AM

Description: Currently, VNodeUtil.getChildIds(vnode) implicitly filters out component placeholders (nodes with componentId). VDomUtil.getChildIds(vdom) likely shares similar logic or intent. This behavior is unintuitive and forced complex workarounds in VdomLifecycle.syncVnodeTree.

Goal: Make getChildIds consistent across both VNodeUtil and VDomUtil, ensuring they can return all children including components.

Proposed Change:

  1. Update VNodeUtil.getChildIds AND VDomUtil.getChildIds to accept an options object, e.g., {includeComponents: true}.
  2. Ensure both utilities behave symmetrically regarding component placeholders/references.
  3. Refactor VdomLifecycle.syncVnodeTree to use this new option.

Benefits:

  • Consistency between VDOM and VNode utilities.
  • Cleaner code in VdomLifecycle.
  • Less "magic" filtering.
tobiu added the ai label on Jan 24, 2026, 12:23 AM
tobiu added the refactoring label on Jan 24, 2026, 12:23 AM
tobiu added the core label on Jan 24, 2026, 12:23 AM