c2213821352/devfest-workshop-mcp
3.1
If you are the rightful owner of devfest-workshop-mcp and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.
This is a Node.js implementation of a Chrome DevTools Model Context Protocol (MCP) server.
Chrome DevTools MCP 服务器
这是一个基于 Node.js 的 Chrome DevTools Model Context Protocol (MCP) 服务器实现。
安装
- 确保您已安装 Node.js
- 在项目目录中运行:
npm install
运行服务器
执行以下命令启动服务器:
npm start
服务器将在 9229 端口启动。
连接到服务器
- 在 Chrome 浏览器中打开 DevTools
- 按 F1 打开设置
- 在 Experiments 部分启用 "Protocol Monitor"
- 使用 Chrome DevTools Protocol 连接到 ws://localhost:9229
VS Code 配置
-
已安装必要的 VS Code 扩展:
- JavaScript Debugger Companion
- Chrome DevTools
-
使用 VS Code 的调试功能可以直接连接到运行中的服务器。
本仓库还包含一个用于记录本次 Workshop 的静态站点,位于 site/ 目录。
本地预览静态站点:
npm run serve
# 打开 http://localhost:8080
网站结构:
site/index.html— 活动首页site/gdg.html— 介绍 GDG / DevFestsite/mcp.html— 介绍 DevTools MCPsite/about.html— 关于参加者(常乐祺)
如需部署到 GitHub Pages,可将 site/ 目录的内容推送到 gh-pages 分支或使用 GitHub Actions 自动部署。