From 5dca3c31d6a5ae7eccf6673f431af6f015af0e61 Mon Sep 17 00:00:00 2001 From: bymyself Date: Sat, 31 Jan 2026 15:19:28 -0800 Subject: [PATCH] docs: add Vue Nodes vs LiteGraph API decision tree to SKILL.md Amp-Thread-ID: https://ampcode.com/threads/T-019c1640-f128-732b-b621-2621ce8b48d1 Co-authored-by: Amp --- .../skills/writing-playwright-tests/SKILL.md | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/.agents/skills/writing-playwright-tests/SKILL.md b/.agents/skills/writing-playwright-tests/SKILL.md index ad080c605..6e1f1206d 100644 --- a/.agents/skills/writing-playwright-tests/SKILL.md +++ b/.agents/skills/writing-playwright-tests/SKILL.md @@ -15,6 +15,32 @@ description: 'Writes Playwright e2e tests for ComfyUI_frontend. Use when creatin - More stable, faster, easier to debug - See [testing/assets.md](testing/assets.md) for details +## Vue Nodes vs LiteGraph: Which API? + +**Choose your approach based on what you're testing:** + +| Rendering Mode | When to Use | API Style | +|----------------|-------------|-----------| +| **Vue Nodes 2.0** | Testing Vue-rendered node UI, DOM widgets, CSS states | `comfyPage.vueNodes.*`, Playwright locators (`getByText`, `getByRole`) | +| **LiteGraph (Canvas)** | Testing canvas interactions, connections, legacy behavior | `comfyPage.getNodeRefByTitle()`, `NodeReference` methods | + +### Vue Nodes 2.0 +```typescript +await comfyPage.setSetting('Comfy.VueNodes.Enabled', true) +await comfyPage.vueNodes.waitForNodes() +const node = comfyPage.vueNodes.getNodeByTitle('KSampler') // Returns Locator +await comfyPage.page.getByText('Load Checkpoint').click() +``` +→ See [features/vue-nodes.md](features/vue-nodes.md) + +### LiteGraph (Canvas) +```typescript +const node = comfyPage.getNodeRefByTitle('KSampler') // Returns NodeReference +await node.click() +const slot = node.getOutputSlot('MODEL') +``` +→ See [core/nodes.md](core/nodes.md) and [core/canvas.md](core/canvas.md) + ## Quick Reference | Task | Load This File |