Agent skill
tool-vitepress
Set up and manage VitePress documentation site with Mermaid diagram support. Use when the user says "render the docs", "start the docs site", "build documentation", "preview docs", or "set up VitePress".
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/tool-vitepress
SKILL.md
VitePress Documentation Site
Commands
init — First-time setup
- Check if
package.jsonexists in the project root - If not, initialize with:
bash
npm init -y npm install -D vitepress vitepress-plugin-mermaid mermaid - Create
.vitepress/config.mtsif it doesn't exist (see Config section below) - Add scripts to
package.json:json{ "scripts": { "docs:dev": "vitepress dev docs", "docs:build": "vitepress build docs", "docs:preview": "vitepress preview docs" } } - Create
docs/index.mdas the landing page if it doesn't exist
dev — Start development server
npm run docs:dev
Opens at http://localhost:5173. Hot-reloads on file changes.
build — Build static site
npm run docs:build
Output goes to docs/.vitepress/dist/.
preview — Preview built site
npm run docs:build && npm run docs:preview
Config
The VitePress config at docs/.vitepress/config.mts should include:
import { defineConfig } from 'vitepress'
import { withMermaid } from 'vitepress-plugin-mermaid'
export default withMermaid(
defineConfig({
title: 'Project Documentation',
description: 'Architecture, decisions, and operational docs',
themeConfig: {
nav: [
{ text: 'PRDs', link: '/prd/' },
{ text: 'RFCs', link: '/rfc/' },
{ text: 'ADRs', link: '/adr/' },
{ text: 'Design', link: '/design/' },
{ text: 'Architecture', link: '/architecture/' },
{ text: 'Runbooks', link: '/runbooks/' },
],
sidebar: 'auto',
search: { provider: 'local' },
},
mermaid: {},
})
)
Directory Structure
VitePress serves from docs/ by default. The skill expects this structure:
docs/
├── .vitepress/
│ └── config.mts
├── index.md # Landing page
├── prd/ # Product requirements
├── rfc/ # Request for comments
├── adr/ # Architecture decision records
├── design/ # Design documents
├── architecture/ # C4 diagrams and architecture docs
├── runbooks/ # Operational runbooks
├── postmortems/ # Incident post-mortems
└── spikes/ # Research spikes
Tips
- Mermaid diagrams render automatically in fenced code blocks with
mermaidlanguage tag - C4 diagrams (C4Context, C4Container, C4Component) are supported via the Mermaid plugin
- Use
[[toc]]in any markdown file to generate a table of contents - VitePress auto-generates sidebar from file structure when
sidebar: 'auto' - Add frontmatter to any doc for custom titles:
---\ntitle: My Custom Title\n---
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?