@marsio/vue-draggable-mcp 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,63 @@
1
+ # @marsio/vue-draggable-mcp
2
+
3
+ vue-draggable 的 MCP 服务器,让 AI IDE 能够精准使用 vue-draggable 组件。
4
+
5
+ > 数据来源:直接基于仓库 `lib/Draggable*.tsx` 的 props 定义,与列表拖拽库无关。
6
+
7
+ ## 工具(精简版)
8
+
9
+ - `get_vue_draggable_docs`:返回完整文档(Markdown)
10
+ - `list_vue_draggable_props`:列出 props 结构化信息(JSON,包含类型/默认值/来源)
11
+ - `get_vue_draggable_type`:获取某个类型的定义(Text)
12
+
13
+ ## 使用
14
+
15
+ ### Cursor / Claude Desktop 配置
16
+
17
+ ```json
18
+ {
19
+ "mcpServers": {
20
+ "vue-draggable": {
21
+ "command": "npx",
22
+ "args": ["@marsio/vue-draggable-mcp"]
23
+ }
24
+ }
25
+ }
26
+ ```
27
+
28
+ ### 本地开发
29
+
30
+ ```bash
31
+ cd mcp
32
+ yarn install
33
+ yarn build
34
+ node dist/index.js
35
+ ```
36
+
37
+ ## 调试
38
+
39
+ ```bash
40
+ # 列出工具
41
+ echo '{"jsonrpc":"2.0","id":1,"method":"tools/list"}' | node dist/index.js
42
+
43
+ # 列出 props(结构化)
44
+ echo '{"jsonrpc":"2.0","id":2,"method":"tools/call","params":{"name":"list_vue_draggable_props","arguments":{"component":"Draggable","includeInherited":false}}}' | node dist/index.js
45
+
46
+ # 获取某个类型定义
47
+ echo '{"jsonrpc":"2.0","id":3,"method":"tools/call","params":{"name":"get_vue_draggable_type","arguments":{"name":"Axis"}}}' | node dist/index.js
48
+
49
+ # 获取完整文档
50
+ echo '{"jsonrpc":"2.0","id":4,"method":"tools/call","params":{"name":"get_vue_draggable_docs","arguments":{}}}' | node dist/index.js
51
+ ```
52
+
53
+ 调用时输出日志:
54
+ ```
55
+ [时间戳] 🔧 Tool called: get_vue_draggable_docs
56
+ [时间戳] 📄 Returning docs (xxxx chars)
57
+ ```
58
+
59
+ ## 发布
60
+
61
+ ```bash
62
+ yarn build && npm publish
63
+ ```
@@ -0,0 +1 @@
1
+ #!/usr/bin/env node