documentation
Use when updating documentation, writing changelogs, or creating technical docs. Provides doc standards and templates.
安装与使用
请根据来源仓库和你的 AI 工具说明安装此技能。先阅读技能文件和依赖要求,再添加到工作流。
查看来源 ↗使用指南技能说明
Documentation Skill
Knowledge for writing and maintaining technical documentation. Read the code before trusting existing docs.
Core Principle
Documentation should match reality, not aspirations.
Always verify against actual code before updating docs.
Documentation Types
README.md
# Project Name
One-line description of what this does.
## Quick Start
Minimum steps to get running:
1. Install: `npm install`
2. Configure: Copy `.env.example` to `.env`
3. Run: `npm run dev`
## Features
- Feature 1 - brief description
- Feature 2 - brief description
## Documentation
- [API Reference](docs/api.md)
- [Configuration](docs/config.md)
- [Contributing](CONTRIBUTING.md)
## License
MIT
CHANGELOG.md
Follow Keep a Changelog format:
# Changelog
All notable changes to this project will be documented in this file.
## [Unreleased]
### Added
- New feature X for doing Y (#123)
### Changed
- Updated Z to handle edge case (#124)
### Fixed
- Bug where A caused B (#125)
### Security
- Patched vulnerability in dependency C
### Removed
- Deprecated feature Q
## [1.2.0] - 2024-01-15
### Added
- User authentication with OAuth
- Password reset flow
### Fixed
- Session timeout not redirecting to login
API Documentation
## Create User
Creates a new user account.
**Endpoint:** `POST /api/users`
**Headers:**
| Header | Required | Description |
|--------|----------|-------------|
| Authorization | Yes | Bearer token |
| Content-Type | Yes | application/json |
**Request Body:**
```json
{
"email": "user@example.com",
"name": "John Doe",
"role": "user"
}
Response: 201 Created
{
"id": "usr_123",
"email": "user@example.com",
"name": "John Doe",
"createdAt": "2024-01-15T10:30:00Z"
}
Errors:
| Code | Description |
|---|---|
| 400 | Invalid request body |
| 409 | Email already exists |
| 401 | Unauthorized |
## Documentation Style Guide
### Principles
1. **Concise** - Brevity over completeness
2. **Practical** - Examples over theory
3. **Accurate** - Verified against code
4. **Scannable** - Headers, bullets, tables
5. **Current** - No outdated information
### Writing Rules
- Use present tense ("Returns" not "Will return")
- Use active voice ("The function returns" not "The value is returned by")
- Use second person sparingly ("You can configure..." is OK)
- Be direct (no "basically", "simply", "just")
- Include code examples for anything non-obvious
### What to Include
- ✅ How to install/setup
- ✅ How to use (with examples)
- ✅ Configuration options
- ✅ Common problems and solutions
- ✅ API reference for public interfaces
### What to Skip
- ❌ Implementation details that may change
- ❌ Obvious code comments
- ❌ Internal architecture (unless for contributors)
- ❌ Future plans (use issues/roadmap instead)
## Update Process
1. **Check git diff** - What files changed?
2. **Read the code** - Understand actual behavior
3. **Compare to docs** - What's now wrong or missing?
4. **Update minimally** - Only what's necessary
5. **Verify accuracy** - Does the doc match the code?
## Detailed References
- [Changelog Format](references/changelog.md) - Full changelog guidelines
- [Style Guide](references/style.md) - Writing style rules
使用示例
查看来源仓库中的使用示例与配置说明。
查看来源 ↗来源历史
- 收录时间
- 2026-01-20
- 索引更新时间
- 2026-01-26
- Branch
- main
收录与同步日期属于本站记录。源码修改历史请查看来源仓库。
GitHub ↗chat Comments (0)
Sign in to join the discussion and leave a comment.
No comments yet. Be the first to share your thoughts!