editable-html
БесплатноЗапускает вложенные скриптыНе проверенLet the user edit the copy of an HTML page or web app in the browser while an agent applies each change to the source in real time. Use when the user asks to…
от dwmkerr★ 25 звёзд на GitHubОб этом скилле
Editable HTML
The user edits text directly on the rendered page. Each edit is queued to a file. The agent watches the queue and applies the change to the real source, so build steps, templates and generated files stay in sync.
browser (press e, click, type)
│ POST /api/dev/live-edit {oldText, newText, binding, tag, parentText}
▼
scratch/live-edit/edits.jsonl ──watched by──▶ agent edits source files
│
scratch/live-edit/applied.jsonl ◀─────────────────┘ (badge shows "N waiting")
Why a queue and not a direct save: the rendered page is rarely the source. Text may come from a template, a script data array, a generator, or a component. The agent knows where it lives; the browser does not.
Pick a mode
| Situation | Mode |
|---|---|
| Static HTML file, visual, one-off page | Static: references/live_edit_server.py serves the page with the script injected |
| App with a dev server (Next.js, Vite, etc.) | App: add a dev-only API route and mount the overlay in dev builds |
| Standalone file the user keeps, no agent loop | Download: E to edit, Cmd+S downloads the edited HTML (see dwmkerr:slides conference mode) |
Default to Static unless the project already has a dev server.
Static mode
- Copy
references/live-edit.jsandreferences/live_edit_server.pyinto./scratch/live-edit/(gitignored). Never into the shipped page. - Start the server in the background:
python3 scratch/live-edit/live_edit_server.py path/to/page.html 8772 scratch/live-edit - Watch the queue with Monitor (or a background
tail), one notification per edit:f=scratch/live-edit/edits.jsonl; touch "$f"; tail -n 0 -F "$f" - Tell the user:
- Open
http://127.0.0.1:8772/page.html - Press
eto toggle edit mode, click any text, type - Click away,
EscorCmd+Ssends the edit - Badge shows how many edits are still waiting
- Reload to see the applied file
- Open
App mode
Copy the shape of the static server into the app:
GET /api/dev/live-editreturns{queued}(lines inedits.jsonlminus lines inapplied.jsonl)POST /api/dev/live-editappends{ts, ...body}toedits.jsonl- Both return 404 unless
NODE_ENV === "development": the route writes to the working tree - Mount
live-edit.js(or a component port of it) only in dev builds - Put the queue outside the app (
LIVE_EDIT_FILEenv var) so a containerised dev server and the host agent share it via a mount
Next.js example: ui/app/api/dev/live-edit/route.ts plus a <LiveEdit /> client component rendered when process.env.NODE_ENV === "development".
Applying edits
For each queued line:
- Read the full line from
edits.jsonl. Monitor notifications truncate long text. - Find
oldTextin the source. Check every place it lives: the shipped file, templates, generator scripts, data files. Fix all of them, or a rebuild reverts the edit. - If
bindingis set, the text comes from script data (e.g.data-text="cap.title"), not the markup. Search the data, not the HTML. - Escape for the target context. A straight
'inside a single-quoted JS string ends the string and breaks the page. Use curly quotes or escape it. - Append
{ts, result: "applied" | "not found" | "skipped", old, new}toapplied.jsonlso the badge count drops. - Report briefly. Flag typos or factual problems in the new copy and suggest a fix, but apply what the user wrote.
A small apply_edit.py <ts> <old> <new> helper that does steps 2, 4 and 5 across a fixed file list is worth writing when edits are frequent.
Make pages edit-friendly
- Text rendered from JS data: add
data-text="<key>"on the element so edits carry a binding. contenteditable="plaintext-only"stops pasted markup leaking into the queue.- The script listens in the capture phase and swallows clicks while editing, so the page's own handlers (steps, carousels, links) do not fire.
Gotchas
- User still sees old text after a structural change. Their open page holds what they typed. Ask them to reload.
- Edit not found. Rendered text differs from source: whitespace, entities (
&),’escapes, text split across elements. Try those forms before giving up. - Server stops with the session. It is a background task. Restart it in a new session.
- Security. Bind to
127.0.0.1only and never ship the script or route. Anything that can POST to it can edit your working tree via the agent.
References
references/live-edit.js: browser overlay (toggle, hover outline, plaintext editing, queue badge)references/live_edit_server.py: static server that injects the overlay and owns the queue
Установить editable-html в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл editable-html?
Let the user edit the copy of an HTML page or web app in the browser while an agent applies each change to the source in real time. Use when the user asks to "make the html editable", "let me edit the text", "live edit", "edit copy in the browser", "watch my edits", or wants to tweak wording on a page, visual, slide or app UI without hunting through the source.
Как установить скилл editable-html?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл editable-html запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
doc-coauthoring
Guide users through a structured workflow for co-authoring documentation. Use when user wants to write documentation, proposals, technical specs, decision…
от Anthropicacademy-guide
Stop and check this skill before finishing any reply to a question about how to use Claude or a Claude product — it recommends matching courses, tutorials…
от Anthropicinternal-comms
A set of resources to help me write all kinds of internal communications, using the formats that my company likes to use. Claude should use this skill…
от Anthropicskill-development
This skill should be used when the user wants to "create a skill", "add a skill to plugin", "write a new skill", "improve skill description", "organize skill…
от Anthropic