HTML To PDF Agent Skill — Development skill for Claude Code
将远程 HTML 网页转换为本地 PDF 文件的 Cursor Agent Skill.
How to install HTML To PDF Agent Skill
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open jamesxjz/html-to-pdf-agent-skill and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What HTML To PDF Agent Skill does
将远程 HTML 网页转换为本地 PDF 文件的 Cursor Agent Skill.
Alternatives in Development
- Book To Skill — Turn any technical book PDF into a Claude Code skill — ready to study, reference, and use while you work 25.9k ★
- Octo Docs — Document delivery with export to PPTX, DOCX, PDF formats 2.8k ★
- Translate Book — Claude Code skill that translates entire books (PDF/DOCX/EPUB) into any language using parallel subagents 542 ★
README
🎯 HTML转PDF - 通用Agent Skill
  
**将远程HTML网页转换为本地PDF文件**
支持单页转换和完整文档转换(自动爬取侧边栏)
✨ 核心特性
- 🚀 智能爬取 - 自动识别SPA,真实提取文档链接(非猜测)
- 📄 完整文档模式 - 爬取整个文档站点并合并为单个PDF
- 🎨 完全控制 - 自定义页面、边距、样式、认证
- ✅ 生产验证 - 已成功转换多个大型文档站点
🌐 兼容性
遵循 [Agent Skills 开放标准](https://agentskills.io/),支持:
✅ **Cursor** | ✅ **Claude Code** | ✅ **Claude.ai** | ✅ **GitHub Copilot** | ✅ **VS Code**
以及所有支持 Agent Skills 的工具(30+)
📦 安装
# 克隆到全局技能目录(推荐)
git clone https://github.com/jamesxjz/html-to-pdf-agent-skill.git ~/.cursor/skills/html-to-pdf
**依赖:**
pip install playwright
playwright install chromium
pip install PyPDF2 # 完整文档模式需要
🚀 使用方法
单页转换
/html-to-pdf https://example.com
完整文档转换(所有章节)
/html-to-pdf https://cursor.com/cn/docs 把这个页面所有文档转为pdf
🎯 实战案例
- ✅ Cursor API文档(96页 → 217页PDF)
- ✅ Cursor中文文档(38章节 → 192页)
- ✅ DeepSeek API文档(18章节 → 50页)
- ✅ AgentSkills文档(11章节 → 65页)
🔥 核心优势
真实爬取 vs 猜测URL
❌ **其他工具**:
urls = ["https://example.com/docs/overview"] # 经常404
✅ **本技能**:
页面.goto("https://example.com/docs")
time.sleep(15) # 等待SPA加载
链接 = 页面.evaluate("() => Array.from(document.querySelectorAll('a'))")
📖 文档
详见 [SKILL.md](SKILL.md) 完整指南
🤝 贡献
欢迎 Issue 和 Pull Request!
📄 License
MIT License - 详见 [LICENSE](LICENSE)
⭐ **如果觉得有用,请给个 Star!** ⭐
Made with ❤️ for the AI coding community
Related Skills
Export All
Generate all output formats (PDF, FDX, HTML) at once.
Export Findings
Export sprint findings to various formats (PDF, DOCX, HTML)
Convert Resume Into HTML
Claude Code slash command that converts a resume PDF/DOCX into a clean, A4-sized HTML page
Browser Render
Render HTML/SVG to a PNG/PDF image without flashing the screen.
Jianli Resume Skill
Claude Code skill|中文简历生成:从真实代码库指纹识别项目与贡献,按岗位/公司 JD 定制,恰好一页 md+HTML+PDF,每条论断可溯源防编造 / A Claude Code skill that g
Paper Humanizer
Claude Code skill: turn a PDF research paper into an interactive HTML reading aid for non-native English reade
Related Agents
Production Coordinator
Delivery specialist for export and format conversion (PDF/FDX/HTML). Use for exports and delivery.
Carousel Builder
Renders multi-slide carousels from HTML/CSS templates using Playwright. Handles slide content injection, brand
Docx Reader
Покровский — факты из текстовых документов (DOCX/XLSX/PPTX/RTF/HTML и PDF с текстовым слоем, route=text-pdf) ч