Designed for the era where AI generates Markdown documents for you.
Copy Optimized for AI — A 1-click CodeLens at the top of your document compresses tables, removes blanks, and copies minified markdown to save LLM tokens.
Hallucination Quick Fix — Automatically underlines AI placeholders ([TODO]) and broken local links. Click the 💡 icon to remove or fix them instantly, or run Fix All.
Context Map (Orphan Scanner) — In the X-Ray sidebar, instantly see which local files link to the current document. Alerts you if an AI-generated document is "Orphaned" (not linked anywhere).
Export (Pro-level Typography)
HTML Export — Saves as a complete HTML file with theme applied
PDF Export — High-quality PDF generation via Chromium with advanced Print CSS best practices
Smart Page Breaks — Gracefully splits code blocks across pages while cloning borders and backgrounds (box-decoration-break: clone)
Table Headers — Repeats table headers across pages when split
Orphan/Widow Control — Prevents single lines of text from being stranded at page edges
Security (Secure by Design)
XSS Protection — Strict HTML sanitization via DOMPurify ensures malicious scripts never execute in the preview
RCE Prevention — PDF exports run in a fully sandboxed Puppeteer environment, preventing system-level exploits
SSRF Blocked — Smart Paste intelligently blocks internal IP tracking and infinite redirect loops
Settings
Setting
Default
Description
marksmith.preview.theme
github
Preview theme (github / dark / minimal)
marksmith.preview.fontSize
16
Preview font size (px)
marksmith.linter.enabled
true
Enable auto-linting on save
marksmith.formatter.onSave
false
Enable auto-format on save
marksmith.export.pdfMargin
20mm
PDF margin
marksmith.smartPaste.enabled
true
Enable Smart Paste
marksmith.smartPaste.imageFolder
assets
Image save folder
marksmith.xray.enabled
true
Enable Document X-Ray
marksmith.xray.checkLinks
false
Auto-check link validity
Commands
Command
Shortcut
Description
Marksmith: Open Enhanced Preview
Cmd+Shift+V
Open preview
Marksmith: Smart Paste
—
Smart paste
Marksmith: Format Document
Cmd+Shift+F
Format document
Marksmith: Lint Document
—
Lint document
Marksmith: Export to HTML
—
Export to HTML
Marksmith: Export to PDF
—
Export to PDF
Support
If you find Marksmith useful, please consider sponsoring the project.