Skip to content

Commit ad9b530

Browse files
2234839claude
andcommitted
docs: move Quick Start to top and remove separate Installation section
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent f7e4c88 commit ad9b530

2 files changed

Lines changed: 52 additions & 68 deletions

File tree

README.md

Lines changed: 26 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -15,40 +15,6 @@ Let AI agents (Claude Code, Cursor, etc.) **see, interact with, and verify** bro
1515

1616
**[简体中文](./README_zh.md)** | English
1717

18-
## Features
19-
20-
- **Zero Config** — Drop-in Vite plugin, works with any Vite project (Vue, React, vanilla JS, etc.)
21-
- **Standalone Server**`npx pilot server` works without Vite, connects to any webpage
22-
- **Compact Snapshot** — Page state serialized into ~80 lines of text, optimized for LLM context windows
23-
- **Multi-Instance** — Each browser tab is independently tracked, switch freely with `instance:xxx` (supports prefix matching) or `PILOT_INSTANCE`
24-
- **Instance Persistence** — Page refreshes reuse the same instance ID, no stale instance buildup
25-
- **Auto Reload** — Browser auto-refreshes when dev server restarts
26-
- **Vue/React Aware**`typeByPlaceholder` dispatches input events for v-model compatibility
27-
- **Element Inspector** — Alt+Click any element to generate a prompt with full context for AI agents
28-
- **Tampermonkey Support** — Install userscript to run on any page automatically
29-
- **Channel Server** — Push prompts directly to Claude Code session via hook-based integration
30-
31-
## Why Not Chrome DevTools MCP?
32-
33-
| | vite-plugin-pilot | Chrome DevTools MCP |
34-
|---|---|---|
35-
| **Connects via** | Dev server injection (SSE + HTTP API) | Chrome DevTools Protocol (CDP) |
36-
| **Requires CDP port** | No | Yes (`--remote-debugging-port`) |
37-
| **WPS Add-ins** | Yes | No (no CDP access) |
38-
| **Electron / embedded browsers** | Yes | Maybe (needs CDP enabled) |
39-
| **Remote debugging** | Yes (browser on any device) | Limited (same network, CDP exposed) |
40-
| **Framework awareness** | Vue/React v-model, scheduler | DOM-only |
41-
| **Zero external deps** | Pure Dev Server injection | Needs Puppeteer/CDP client |
42-
| **Production sites** | Yes (standalone server + bridge.js) | Needs CDP exposed |
43-
44-
## Installation
45-
46-
```bash
47-
pnpm add -D vite-plugin-pilot
48-
# or
49-
npm install -D vite-plugin-pilot
50-
```
51-
5218
## Quick Start
5319

5420
### Option 1: Vite Plugin Mode
@@ -77,6 +43,32 @@ npx pilot page # View page snapshot
7743
npx pilot status # List connected instances
7844
```
7945

46+
## Features
47+
48+
- **Zero Config** — Drop-in Vite plugin, works with any Vite project (Vue, React, vanilla JS, etc.)
49+
- **Standalone Server**`npx pilot server` works without Vite, connects to any webpage
50+
- **Compact Snapshot** — Page state serialized into ~80 lines of text, optimized for LLM context windows
51+
- **Multi-Instance** — Each browser tab is independently tracked, switch freely with `instance:xxx` (supports prefix matching) or `PILOT_INSTANCE`
52+
- **Instance Persistence** — Page refreshes reuse the same instance ID, no stale instance buildup
53+
- **Auto Reload** — Browser auto-refreshes when dev server restarts
54+
- **Vue/React Aware**`typeByPlaceholder` dispatches input events for v-model compatibility
55+
- **Element Inspector** — Alt+Click any element to generate a prompt with full context for AI agents
56+
- **Tampermonkey Support** — Install userscript to run on any page automatically
57+
- **Channel Server** — Push prompts directly to Claude Code session via hook-based integration
58+
59+
## Why Not Chrome DevTools MCP?
60+
61+
| | vite-plugin-pilot | Chrome DevTools MCP |
62+
|---|---|---|
63+
| **Connects via** | Dev server injection (SSE + HTTP API) | Chrome DevTools Protocol (CDP) |
64+
| **Requires CDP port** | No | Yes (`--remote-debugging-port`) |
65+
| **WPS Add-ins** | Yes | No (no CDP access) |
66+
| **Electron / embedded browsers** | Yes | Maybe (needs CDP enabled) |
67+
| **Remote debugging** | Yes (browser on any device) | Limited (same network, CDP exposed) |
68+
| **Framework awareness** | Vue/React v-model, scheduler | DOM-only |
69+
| **Zero external deps** | Pure Dev Server injection | Needs Puppeteer/CDP client |
70+
| **Production sites** | Yes (standalone server + bridge.js) | Needs CDP exposed |
71+
8072
## Browser-to-Claude Code (Channel Server)
8173

8274
Push prompts directly from the browser to your running Claude Code session — no copy-paste needed.

README_zh.md

Lines changed: 26 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -10,40 +10,6 @@
1010

1111
English | **[简体中文](./README_zh.md)**
1212

13-
## 特性
14-
15-
- **零配置** — Vite 插件即插即用,支持任何 Vite 项目(Vue、React、原生 JS 等)
16-
- **独立运行** — 不依赖 Vite,`npx pilot server` 即可连接任意网页
17-
- **紧凑快照** — 页面状态序列化为 ~80 行文本,针对 LLM 上下文窗口优化
18-
- **多实例** — 每个浏览器 tab 独立追踪,通过 `instance:xxx`(支持前缀模糊匹配)或 `PILOT_INSTANCE` 自由切换
19-
- **实例持久化** — 页面刷新复用同一 instance ID,不会堆积过期实例
20-
- **自动刷新** — Dev server 重启后浏览器自动刷新
21-
- **Vue/React 兼容**`typeByPlaceholder` 触发 input 事件,兼容 v-model
22-
- **Element Inspector** — Alt+Click 选中元素,生成含完整信息的提示词,供 AI Agent 使用
23-
- **Tampermonkey 支持** — 安装 userscript 后自动在所有页面运行
24-
- **Channel Server** — 浏览器端提示词可直接推送到 Claude Code session(通过 UserPromptSubmit hook)
25-
26-
## 为什么不直接用 Chrome DevTools MCP?
27-
28-
| | vite-plugin-pilot | Chrome DevTools MCP |
29-
|---|---|---|
30-
| **连接方式** | Dev server 注入(SSE + HTTP API) | Chrome DevTools Protocol (CDP) |
31-
| **需要 CDP 端口** | 不需要 | 需要(`--remote-debugging-port`|
32-
| **WPS 加载项** | 支持 | 不支持(无法访问 CDP) |
33-
| **Electron / 嵌入式浏览器** | 支持 | 不确定(需开启 CDP) |
34-
| **远程调试** | 支持(浏览器可在任意设备) | 受限(需同一网络 + 暴露 CDP) |
35-
| **框架感知** | Vue/React v-model、scheduler | 仅操作 DOM |
36-
| **外部依赖** | 纯 Dev Server 注入,零依赖 | 需要 Puppeteer / CDP 客户端 |
37-
| **线上页面** | 支持(独立 Server + bridge.js) | 需要暴露 CDP |
38-
39-
## 安装
40-
41-
```bash
42-
pnpm add -D vite-plugin-pilot
43-
#
44-
npm install -D vite-plugin-pilot
45-
```
46-
4713
## 快速开始
4814

4915
### 方式一:Vite 插件模式
@@ -72,6 +38,32 @@ npx pilot page # 查看页面快照
7238
npx pilot status # 查看连接的实例列表
7339
```
7440

41+
## 特性
42+
43+
- **零配置** — Vite 插件即插即用,支持任何 Vite 项目(Vue、React、原生 JS 等)
44+
- **独立运行** — 不依赖 Vite,`npx pilot server` 即可连接任意网页
45+
- **紧凑快照** — 页面状态序列化为 ~80 行文本,针对 LLM 上下文窗口优化
46+
- **多实例** — 每个浏览器 tab 独立追踪,通过 `instance:xxx`(支持前缀模糊匹配)或 `PILOT_INSTANCE` 自由切换
47+
- **实例持久化** — 页面刷新复用同一 instance ID,不会堆积过期实例
48+
- **自动刷新** — Dev server 重启后浏览器自动刷新
49+
- **Vue/React 兼容**`typeByPlaceholder` 触发 input 事件,兼容 v-model
50+
- **Element Inspector** — Alt+Click 选中元素,生成含完整信息的提示词,供 AI Agent 使用
51+
- **Tampermonkey 支持** — 安装 userscript 后自动在所有页面运行
52+
- **Channel Server** — 浏览器端提示词可直接推送到 Claude Code session(通过 UserPromptSubmit hook)
53+
54+
## 为什么不直接用 Chrome DevTools MCP?
55+
56+
| | vite-plugin-pilot | Chrome DevTools MCP |
57+
|---|---|---|
58+
| **连接方式** | Dev server 注入(SSE + HTTP API) | Chrome DevTools Protocol (CDP) |
59+
| **需要 CDP 端口** | 不需要 | 需要(`--remote-debugging-port`|
60+
| **WPS 加载项** | 支持 | 不支持(无法访问 CDP) |
61+
| **Electron / 嵌入式浏览器** | 支持 | 不确定(需开启 CDP) |
62+
| **远程调试** | 支持(浏览器可在任意设备) | 受限(需同一网络 + 暴露 CDP) |
63+
| **框架感知** | Vue/React v-model、scheduler | 仅操作 DOM |
64+
| **外部依赖** | 纯 Dev Server 注入,零依赖 | 需要 Puppeteer / CDP 客户端 |
65+
| **线上页面** | 支持(独立 Server + bridge.js) | 需要暴露 CDP |
66+
7567
## 浏览器直连 Claude Code(Channel Server)
7668

7769
浏览器中 Alt+Click 的提示词可直接推送到当前 Claude Code session,无需复制粘贴。

0 commit comments

Comments
 (0)