joe-markdown-to-docx
暂无简介
- License 许可
- MIT
- 最近更新
- 2026-06-10
- Stars
- ★ 3
- Forks
- 0
03 SKILL.md 正文
Markdown to DOCX Converter
Convert Markdown documents to professional Word DOCX format with full formatting preservation.
Features
- ✅ Complete Markdown support: Headers, paragraphs, lists, code blocks
- ✅ Tables: Full table support with alignment (left/center/right)
- ✅ Images: Local files, remote URLs, and data URLs
- ✅ Text formatting: Bold, italic, inline code, links
- ✅ Code blocks: Syntax-highlighted with borders and background
- ✅ GFM support: GitHub Flavored Markdown extensions
Installation
After installing this skill, run:
cd ~/.openclaw/workspace/skills/markdown-to-docx
npm install
All dependencies are pure JavaScript and work on Windows, macOS, and Linux.
Usage
Convert a Markdown file to DOCX:
node scripts/convert.js <input.md> [output.docx]
Examples
# Convert with auto-generated output name
node scripts/convert.js document.md
# Specify output filename
node scripts/convert.js document.md report.docx
# Convert from current directory
node scripts/convert.js ./README.md ./README.docx
Supported Markdown Features
Text Formatting
- Bold:
**text**or__text__ - Italic:
*text*or_text_ Inline code:`code`- Links:
[text](url)
Tables
| Header 1 | Header 2 | Header 3 |
|:---------|:--------:|---------:|
| Left | Center | Right |
- Alignment:
:---(left),:---:(center),---:(right) - Header row with gray background
- Bordered cells with padding
Images


- Local images: Relative paths from Markdown file location
- Remote images: HTTP/HTTPS URLs (automatically downloaded)
- Data URLs: Base64-encoded images
- Auto-centered with appropriate sizing
Code Blocks
```javascript
function hello() {
console.log("Hello!");
}
```
- Monospace font (Consolas)
- Light gray background
- Border styling
Output Format
Generated DOCX files include:
- 1-inch margins on all sides
- Professional spacing and alignment
- Consistent styling throughout
- Editable in Microsoft Word, Google Docs, LibreOffice
Error Handling
- Missing images: Shows placeholder text instead of breaking
- Network errors: Graceful fallback with error message
- Invalid Markdown: Skips unsupported elements
Dependencies
Automatically installed via npm install:
docx: Word document generationunified,remark-parse,remark-gfm: Markdown parsingnode-fetch: Remote image downloading
04 同仓库更多 Skills
youtube-content
YouTube transcripts to summaries, threads, blogs.
xurl
X/Twitter via xurl CLI: post, search, DM, media, v2 API.
touchdesigner-mcp
Control a running TouchDesigner instance via twozero MCP — create operators, set parameters, wire connections, execute Python, build real-time visuals. 36 native tools.
test-driven-development
TDD: enforce RED-GREEN-REFACTOR, tests before code.
teams-meeting-pipeline
Operate the Teams meeting summary pipeline via Hermes CLI — summarize meetings, inspect pipeline status, replay jobs, manage Microsoft Graph subscriptions.
systematic-debugging
4-phase root cause debugging: understand bugs before fixing.