AI Skills
DocsLit ships two skill files that you can install into AI coding agents. Once installed, the agent knows every wc-* component, the correct attribute names, nesting rules, and frontmatter format — so it can write valid DocsLit pages without guessing.
Available skills
Installing skills
Skills are Markdown files that live in the DocsLit GitHub repository. Install them by downloading the file and pointing your agent at it.
Add the skill file to your project's .claude/ directory:
Then reference them from your CLAUDE.md:
Add the skill file as a Cursor rule:
Cursor picks up .mdc files from the rules directory automatically.
Add the skill file as a Windsurf rule:
Or append it to an existing .windsurfrules file. For migration support, concatenate both skill files.
Most AI coding agents support a system prompt or rules file. Download the skill Markdown file and include it in whatever mechanism your agent uses for persistent instructions.
The skill files are plain Markdown with no special syntax — they work with any agent that reads instruction files.
Using the authoring skill
Once the authoring skill is installed, your agent can write valid DocsLit pages. Ask it to create pages and it will use the correct components and syntax.
Example prompts
The agent will produce a .md file with proper frontmatter, <wc-steps> for the flow, <wc-code-group> for multi-language examples, and <wc-callout> blocks for important notes.
The agent will use <wc-endpoint>, <wc-fields>, and <wc-field> components with the correct attributes like method, url, type, and required.
The agent will use <wc-tiles cols="3"> with <wc-tile> children, each with title, description, href, and icon-name attributes.
Using the migration skill
The migration skill teaches the agent the exact mapping from MDX components to DocsLit wc-* components. Point it at your existing docs and let it convert them.
Follow the installation steps above for your agent.
Set up a new DocsLit project to receive the converted files:
Point the agent at your existing docs directory:
Convert all the MDX files in ../old-docs/pages/ to DocsLit format. Put the output in docs/. Update docslit.json with the correct sidebar structure.
The agent will handle component conversion, attribute renames, frontmatter normalization, and config generation.
Run the DocsLit validator to catch any issues:
The validator checks for broken links, unknown components, missing frontmatter, and orphaned files.
import command that handles migration programmatically. See the migration guides for details. The skill is useful when you want AI-assisted migration with more control over the output, or when converting from platforms the import command does not support.What the migration skill converts
MDX callouts like <Note>, <Tip>, <Warning>, <Danger>, <Info>, <Check>, and <Success> convert to <wc-callout> with the appropriate type and title attributes.
<Card> becomes <wc-card> with icon renamed to icon-name. <CardGroup> becomes <wc-tiles>. <Columns> becomes <wc-columns> and <Column> wrappers are removed.
<Tabs> and <Tab> convert to <wc-tabs> and <wc-tab>, with title renamed to label. <Steps> and <Step> convert to <wc-steps> and <wc-step> with auto-numbering.
<ParamField> becomes <wc-field> with location attributes (path, query, body, header) flattened to name. <ResponseField> also becomes <wc-field>.
<Tooltip> tags are removed but inner text is kept. <Icon> tags are removed entirely. <Snippet> tags are flattened. These may need manual replacement with DocsLit equivalents.
Keeping skills up to date
The skill files track the latest DocsLit component set. When DocsLit adds new components or changes attributes, update your local copies:
Next steps
- Learn about MCP server integration for giving agents live access to your docs
- Explore all available components
- Try the built-in import command for automated migration