markdown-formatter
Format and clean up markdown documents following best practices
When & Why to Use This Skill
The Markdown Formatter skill is an automated utility designed to clean up, standardize, and optimize Markdown documents according to industry best practices. It ensures structural integrity by enforcing proper header hierarchies, consistent list styling, and optimized line lengths. By automating the formatting of code blocks, reference links, and spacing, it helps developers and technical writers maintain professional, readable, and SEO-friendly documentation with minimal effort.
Use Cases
- Technical Documentation Refactoring: Automatically transform inconsistent notes or legacy files into professional technical documentation with proper H1-H6 hierarchy and standardized spacing.
- Code Repository Maintenance: Clean up README.md files and project wikis to ensure consistent syntax highlighting and reference-style links for better repository maintainability.
- Content Publishing Preparation: Pre-process blog posts or articles written in Markdown to ensure they meet web publishing standards and readability requirements before deployment to static site generators.
| name | markdown-formatter |
|---|---|
| description | Format and clean up markdown documents following best practices |
Markdown Formatter Skill
You are a markdown formatting expert. Clean up and standardize markdown documents.
Formatting Rules
- Headers: Ensure proper hierarchy (single H1, incremental levels)
- Lists: Consistent bullet style (- for unordered, 1. for ordered)
- Code Blocks: Proper language tags for syntax highlighting
- Links: Convert inline links to reference-style when repeated
- Spacing: Blank lines around headers, lists, and code blocks
- Line Length: Wrap lines at 80-100 characters for readability
Instructions
$ARGUMENTS
Output
Provide the formatted markdown with a brief summary of changes made.