Agent skill
documentation
Expert at TSDoc comments, Storybook stories, VitePress docs, TypeDoc API generation. Use when documenting code, adding comments, creating stories, or generating API docs.
Install this agent skill to your Project
npx add-skill https://github.com/aiskillstore/marketplace/tree/main/skills/crazyswami/documentation
SKILL.md
Documentation Specialist
You are an expert at documenting TypeScript/React codebases using TSDoc, Storybook, VitePress, and TypeDoc.
When To Use
Claude should automatically use this skill when:
- User asks to document code, functions, hooks, or components
- User mentions TSDoc, Storybook, VitePress, or API docs
- Creating or updating documentation files
- Adding JSDoc/TSDoc comments to exports
TSDoc Format
Functions
/**
* Brief description of what this function does.
*
* @param paramName - Description of the parameter
* @returns Description of the return value
*
* @example
* ```typescript
* const result = functionName(arg);
* ```
*/
React Hooks
/**
* Brief description of the hook's purpose.
*
* @param options - Configuration options
* @returns Object containing state and actions
*
* @example
* ```tsx
* const { data, loading } = useHookName({ id: '123' });
* ```
*/
React Components
/**
* Brief description of the component.
*
* @example
* ```tsx
* <ComponentName prop="value" />
* ```
*/
Interfaces
/**
* Description of what this type represents.
*
* @example
* ```typescript
* const config: TypeName = { key: 'value' };
* ```
*/
Storybook Stories
Every component in src/components/ needs a .stories.tsx file:
import type { Meta, StoryObj } from '@storybook/react';
import { ComponentName } from './ComponentName';
const meta: Meta<typeof ComponentName> = {
title: 'Components/ComponentName',
component: ComponentName,
tags: ['autodocs'],
parameters: {
layout: 'padded',
docs: {
description: {
component: 'Description of what this component does.',
},
},
},
};
export default meta;
type Story = StoryObj<typeof ComponentName>;
export const Default: Story = {
args: {},
};
export const Loading: Story = {
args: { isLoading: true },
};
export const Error: Story = {
args: { error: 'Something went wrong' },
};
Commands
| Command | Description |
|---|---|
pnpm docs:api |
Generate API docs from TSDoc with TypeDoc |
pnpm docs:dev |
Start VitePress dev server |
pnpm docs:build |
Build VitePress static site |
pnpm storybook |
Start Storybook dev server |
File Locations
| Type | Location |
|---|---|
| TSDoc | Inline in .ts/.tsx files |
| Storybook | src/components/*.stories.tsx |
| VitePress | docs/**/*.md |
| TypeDoc output | docs/api/generated/ |
| TypeDoc config | typedoc.json |
Checklist
When documenting:
- All exported functions have TSDoc with @param, @returns, @example
- All exported hooks have TSDoc with usage examples
- All components have TSDoc and Storybook stories
- All interfaces/types have TSDoc with examples
- VitePress sidebar updated if new pages added
- Run
pnpm docs:apito regenerate API docs
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
perigon-backend
Perigon ASP.NET Core + EF Core + Aspire conventions
perigon-agent
Pointers for Copilot/agents to apply Perigon conventions
perigon-angular
Angular 21+ standalone/Material/signal conventions for Perigon WebApp
fastapi-mastery
Comprehensive FastAPI development skill covering REST API creation, routing, request/response handling, validation, authentication, database integration, middleware, and deployment. Use when working with FastAPI projects, building APIs, implementing CRUD operations, setting up authentication/authorization, integrating databases (SQL/NoSQL), adding middleware, handling WebSockets, or deploying FastAPI applications. Triggered by requests involving .py files with FastAPI code, API endpoint creation, Pydantic models, or FastAPI-specific features.
context7-efficient
Token-efficient library documentation fetcher using Context7 MCP with 86.8% token savings through intelligent shell pipeline filtering. Fetches code examples, API references, and best practices for JavaScript, Python, Go, Rust, and other libraries. Use when users ask about library documentation, need code examples, want API usage patterns, are learning a new framework, need syntax reference, or troubleshooting with library-specific information. Triggers include questions like "Show me React hooks", "How do I use Prisma", "What's the Next.js routing syntax", or any request for library/framework documentation.
browser-use
Browser automation using Playwright MCP. Navigate websites, fill forms, click elements, take screenshots, and extract data. Use when tasks require web browsing, form submission, web scraping, UI testing, or any browser interaction.
Didn't find tool you were looking for?