LearnNewsExamplesServices
Frontmatter
id13186
titlefeat: remove_component Slice 2 — existence-probe + snapshot-for-undo + e2e proof
stateClosed
labels
enhancementai
assigneesneo-opus-vega
createdAtJun 14, 2026, 7:04 AM
updatedAtJun 14, 2026, 10:26 AM
githubUrlhttps://github.com/neomjs/neo/issues/13186
authorneo-opus-vega
commentsCount0
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtJun 14, 2026, 10:26 AM

feat: remove_component Slice 2 — existence-probe + snapshot-for-undo + e2e proof

neo-opus-vega
neo-opus-vega commented on Jun 14, 2026, 7:04 AM

Summary

Slice 2 of remove_component (parent: #9847). Slice 1 (#13188, merged) shipped the thin write-locked tool. This ticket is re-scoped (2026-06-14) to the now-unblocked, high-value part: the e2e removal proof. The snapshot-for-undo + existence-probe are deferred (below) — the snapshot belongs to the Transaction/Undo stack #9848.

Delivered (this slice)

  • get_component_tree absence proof (e2e)test/playwright/e2e/NeuralLinkRemoveComponent.spec.mjs: create a probe via create_component → assert present (tree + DOM) → remove_component it → assert gone from get_component_tree AND the live DOM. Proves Slice 1's destroy(true) behavior (instance deregistration + parent-vdom detach) end-to-end, and that create + remove compose over one live session. Now unblocked by #13188 (Slice 1) + the NL-e2e foundation (#13183 / #13191) all merging.

Deferred

  • Snapshot-for-undo (snapshot: true capturing config for recreate) + E2E snapshot integrity (remove → recreate round-trip) — these are reversibility, owned by the Transaction/Undo stack epic #9848. No standalone value until the undo stack exists; tracked there, not duplicated here.
  • Existence-probe (server-side pre-check before destroy) — a marginal hardening: Slice 1 presence-validates componentId, and a non-existent id already surfaces a worker-side error. Deferred as low-ROI unless an idempotent-no-op contract (à la the FM removeAgentRepo absent→no-op) is later wanted.

Architectural Context

  • Neo.component.Base.destroy(updateParentVdom, silent) is the core destruction method; Slice 1 pins updateParentVdom=true (the default destroy(false) orphans the DOM node).

Refs #9847, #9848.

Authored by @neo-opus-vega (Vega, Claude Opus 4.8) — origin session a0bc6b23-78c5-4bd7-b944-9db5e236f42d.