Content Creation Guide
Learn how to create and organize high-quality documentation content in LeafMove Smart Documentation Center.
📝 Markdown Basics
Headers
# Level 1 Header
## Level 2 Header
### Level 3 Header
#### Level 4 Header
Text Formatting
**Bold text**
*Italic text*
~~Strikethrough~~
`Inline code`
Lists
# Unordered list
- Item 1
- Item 2
- Sub-item 2.1
- Sub-item 2.2
# Ordered list
1. First item
2. Second item
3. Third item
Links and Images
# Links
[Link text](./other-file.md)
[External link](https://example.com)
# Images


Code Blocks
```javascript
function hello() {
console.log('Hello, World!');
}
### Tables
```markdown
| Column 1 | Column 2 | Column 3 |
|----------|----------|----------|
| Data 1 | Data 2 | Data 3 |
| Data 4 | Data 5 | Data 6 |
🎨 VuePress Extensions
Alert Boxes
::: tip Tip
This is a tip box
:::
::: warning Warning
This is a warning box
:::
::: danger Danger
This is a danger box
:::
::: info Information
This is an info box
:::
Code Groups
::: code-group
```js [JavaScript]
console.log('Hello from JavaScript');
print('Hello from Python')
echo "Hello from Shell"
:::
## 📁 File Organization
### Directory Structure
docs/ ├── README.md # Homepage ├── guide/ # User guide │ ├── README.md # Guide homepage │ ├── getting-started.md # Quick start │ ├── configuration.md # Configuration │ └── content-creation.md # Content creation ├── api/ # API documentation │ ├── README.md # API overview │ ├── authentication.md # Authentication │ └── endpoints/ # Endpoint details │ ├── users.md # User endpoints │ └── projects.md # Project endpoints └── examples/ # Examples and tutorials ├── README.md ├── basic-usage.md └── advanced-topics.md
### File Naming Conventions
1. **Use lowercase**: All filenames should use lowercase letters
2. **Use hyphens**: Separate words with hyphens `-`
3. **Be descriptive**: Filenames should clearly describe content
4. **Avoid special characters**: No spaces, Chinese characters, or special symbols
**Examples**:
✅ Recommended getting-started.md api-reference.md user-management.md
❌ Avoid Getting Started.md API参考.md user_management.md
### README.md Files
Each directory should contain a `README.md` file as the homepage:
```markdown
# Directory Title
Brief description of the directory's content and purpose.
## Content Overview
- [Document 1](./file1.md) - Brief description of document 1
- [Document 2](./file2.md) - Brief description of document 2
- [Subdirectory](./subdirectory/) - Description of subdirectory
## Quick Navigation
Provide quick navigation links based on user needs.
🎨 Content Design
Document Structure Template
Technical Documentation Template
# Document Title
> Brief description of the document's purpose and scope
## Overview
Detailed introduction to the document's background, objectives, and main content.
## Prerequisites
List the prerequisite knowledge or environment requirements for using this document.
## Main Content
### Section 1
Detailed explanation...
### Section 2
Detailed explanation...
## Examples
Provide practical usage examples.
## FAQ
List common questions and solutions.
## Related Resources
- [Related Document 1](./related1.md)
- [Related Document 2](./related2.md)
API Documentation Template
# API Name
## Description
Brief description of the API's functionality and purpose.
## Request Information
- **Method**: GET/POST/PUT/DELETE
- **Path**: `/api/endpoint`
- **Content-Type**: `application/json`
## Request Parameters
| Parameter | Type | Required | Default | Description |
|-----------|------|----------|---------|-------------|
| param1 | string | Yes | - | Parameter description |
| param2 | number | No | 0 | Parameter description |
## Response Format
```json
{
"code": 200,
"message": "success",
"data": {
// Response data
}
}
Usage Examples
cURL Example
curl -X GET "https://api.example.com/endpoint" \
-H "Authorization: Bearer TOKEN"
JavaScript Example
const response = await fetch('/api/endpoint', {
method: 'GET',
headers: {
'Authorization': 'Bearer TOKEN'
}
});
Error Codes
Error Code | Description | Solution |
---|---|---|
400 | Bad Request | Check parameter format |
401 | Unauthorized | Check authentication |
## 🖼 Images and Media
### Image Management
1. **Storage Location**: Store images in `docs/.vuepress/public/images/`
2. **Naming Convention**: Use descriptive filenames
3. **Format Selection**:
- Screenshots: PNG format
- Photos: JPG format
- Icons: SVG format
### Image References
```markdown
# Absolute path (recommended)

# Relative path

# Image with link
[](/images/screenshot-large.png)
Image Optimization
- Size Control: Keep image file size under 500KB
- Resolution: Use appropriate resolution, typically 72-150 DPI
- Compression: Use image compression tools to reduce file size
🔗 Link Management
Internal Links
# Relative path links (recommended)
[Link text](./other-file.md)
[Link text](../other-dir/file.md)
# Anchor links
[Jump to section](#section-title)
# Links with query parameters
[Link text](./file.md#section)
External Links
# Regular external link
[GitHub](https://github.com)
# Open in new window
[GitHub](https://github.com){target="_blank"}
Link Checking
Regularly check links in documents for validity:
- Internal Links: Ensure referenced files exist
- External Links: Regularly verify external link validity
- Anchor Links: Ensure corresponding headings exist
✅ Content Quality
Writing Principles
- Clear and Concise: Use simple and clear language
- Logical Structure: Organize content in logical order
- User-Oriented: Think and organize content from user perspective
- Practical: Provide actionable specific steps
Quality Checklist
- [ ] Clear title hierarchy
- [ ] Logical content structure
- [ ] Accurate language expression
- [ ] Runnable example code
- [ ] Clear and meaningful images
- [ ] Valid and accessible links
- [ ] Consistent formatting
- [ ] Correct spelling and grammar
🔄 Version Management
Git Workflow
- Create Branch: Create separate branch for each document update
- Commit Changes: Use clear commit messages
- Code Review: Review through Pull Request
- Merge and Publish: Merge to main branch after review
Commit Message Standards
# New documentation
git commit -m "docs: add user management API documentation"
# Update documentation
git commit -m "docs: update installation guide dependency versions"
# Fix documentation
git commit -m "docs: fix broken links in quick start guide"