markdown-formatter
Format and beautify markdown documents with configurable styles. Preserve structure, fix formatting, ensure consistency.
от HKU-MMLab★ 40 звёзд на GitHub
Установить markdown-formatter в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
Markdown-Formatter - Beautify Your Markdown
Vernox Utility Skill - Make your markdown look professional.
Overview
Markdown-Formatter is a powerful tool for formatting, linting, and beautifying markdown documents. Supports multiple style guides (CommonMark, GitHub Flavored Markdown, custom rules) and handles everything from simple cleanup to complex reformatting.
Features
✅ Formatter Engine
- Multiple style guides (CommonMark, GitHub, custom)
- Preserves document structure
- Handles nested lists, code blocks, tables
- Configurable line width and indentation
- Smart heading normalization
- Link reference optimization
✅ Linting & Cleanup
- Remove trailing whitespace
- Normalize line endings (LF vs CRLF)
- Fix inconsistent list markers
- Remove empty lines at end
- Fix multiple consecutive blank lines
✅ Beautification
- Improve heading hierarchy
- Optimize list formatting
- Format code blocks with proper spacing
- Wrap long lines at configured width
- Add proper spacing around emphasis
✅ Validation
- Check markdown syntax validity
- Report linting errors
- Suggest improvements
- Validate links and references
Runtime
This workspace injects the skill at /root/skills/markdown-formatter. Use the
provided files directly; do not install the skill during the user task.
Quick Start
Format a Document
const result = await formatMarkdown({
markdown: '# My Document\n\n\n## Section 1\nContent here...',
style: 'github',
options: {
maxWidth: 80,
headingStyle: 'atx'
}
});
console.log(result.formattedMarkdown);
Beautify Multiple Files
const results = await formatBatch({
markdownFiles: ['./doc1.md', './doc2.md', './README.md'],
style: 'github',
options: { wrapWidth: 80 }
});
results.forEach(result => {
console.log(`${result.file}: ${result.warnings} warnings`);
});
Lint and Fix
const result = await lintMarkdown({
markdown: '# My Document\n\n\nBad list\n\n- item 1\n- item 2',
style: 'github'
});
console.log(`Errors found: ${result.errors}`);
console.log(`Fixed: ${result.fixed}`);
Tool Functions
formatMarkdown
Format markdown content according to style guide.
Parameters:
markdown(string, required): Markdown content to formatstyle(string, required): Style guide name ('commonmark', 'github', 'commonmark', 'custom')options(object, optional):maxWidth(number): Line wrap width (default: 80)headingStyle(string): 'atx' | 'setext' | 'underlined' | 'consistent' (default: 'atx')listStyle(string): 'consistent' | 'dash' | 'asterisk' | 'plus' (default: 'consistent')codeStyle(string): 'fenced' | 'indented' (default: 'fenced')emphasisStyle(string): 'underscore' | 'asterisk' (default: 'asterisk')strongStyle(string): 'asterisk' | 'underline' (default: 'asterisk')linkStyle(string): 'inline' | 'reference' | 'full' (default: 'inline')preserveHtml(boolean): Keep HTML as-is (default: false)fixLists(boolean): Fix inconsistent list markers (default: true)normalizeSpacing(boolean): Fix spacing around formatting (default: true)
Returns:
formattedMarkdown(string): Formatted markdownwarnings(array): Array of warning messagesstats(object): Formatting statisticslintResult(object): Linting errors and fixesoriginalLength(number): Original character countformattedLength(number): Formatted character count
formatBatch
Format multiple markdown files at once.
Parameters:
markdownFiles(array, required): Array of file pathsstyle(string): Style guide nameoptions(object, optional): Same as formatMarkdown options
Returns:
results(array): Array of formatting resultstotalFiles(number): Number of files processedtotalWarnings(number): Total warnings across all filesprocessingTime(number): Time taken in ms
lintMarkdown
Check markdown for issues without formatting.
Parameters:
markdown(string, required): Markdown content to lintstyle(string): Style guide nameoptions(object, optional): Additional linting optionscheckLinks(boolean): Validate links (default: true)checkHeadingLevels(boolean): Check heading hierarchy (default: true)checkListConsistency(boolean): Check list marker consistency (default: true)checkEmphasisBalance(boolean): Check emphasis pairing (default: false)
Returns:
errors(array): Array of error objectswarnings(array): Array of warning objectsstats(object): Linting statisticssuggestions(array): Suggested fixes
Style Guides
CommonMark (default)
- Standard CommonMark specification
- ATX headings (ATX-style)
- Reference-style links [text]
- Underscore emphasis
- Asterisk emphasis
GitHub Flavored Markdown
- Fenced code blocks with ```
- Tables with pipes
- Task lists [ ] with x
- Strikethrough
~~text~~ - Autol
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
- README.md
- _meta.json
- config.json
- index.js
- package.json
- test.js
FAQ
Что делает скилл markdown-formatter?
Format and beautify markdown documents with configurable styles. Preserve structure, fix formatting, ensure consistency.
Как установить скилл markdown-formatter?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл markdown-formatter запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
theme-factory
AnthropicToolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
access
AnthropicManage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
configure
AnthropicSet up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
access
AnthropicManage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…