开发者文档抓取工具
抓取任意开发者文档并将其保存为本地 Markdown 文件,使用 MCP 协议标准化通信。
快速入门
安装
全局安装:
npm install -g downmarked
或者使用 npx:
npx downmarked fetch https://reactjs.org/docs/getting-started.html
基础用法
downmarked fetch <url>
选项
-o, --output <path>
:输出路径-s, --selector <selector>
:CSS 选择器定位内容-r, --recursive
:递归抓取链接页面-d, --max-depth <number>
:递归最大深度(默认3)--split
:按标题分割文档
示例
抓取 React 文档:
downmarked fetch https://reactjs.org/docs/getting-started.html -o ~/Documents/react-docs.md