Generate stylish resumes from Markdown with Vite, UnoCSS, and markdown-it!
Export as PDF, PNG, or JPEG — with live preview and hot reloading.
| Feature | v1 (Before) | v2.1 (Now - Vite) |
|---|---|---|
| Live Preview | nodemon + Express |
✅ Vite Dev Server |
| Hot Reload | ❌ Manual refresh | ✅ Automatic via Vite |
| Markdown Parsing | marked (basic) |
✅ markdown-it + markdown-it-attrs |
| Theme Styling | Manual CSS | ✅ UnoCSS utility-first styling |
| Frontend Build | None | ✅ Vite bundler |
| Injection System | Basic string replace | ✅ Dynamic + revertible templates |
| Export Formats | Only PDF | ✅ PDF, PNG, JPEG |
| Custom Classes | Not supported | ✅ Tailwind-style in .md |
markdown-cv-builder is a modern toolchain for converting Markdown resumes into responsive, beautifully styled web pages and documents.
- ✅ Powered by Vite
- 🎨 Styled with UnoCSS (Tailwind-compatible)
- ✍️ Uses markdown-it for flexible parsing
- 📄 Outputs PDF, PNG, or JPEG via Puppeteer
- ♻️ Auto-replaces theme content and restores templates
| Command | Description |
|---|---|
pnpm start |
Inject markdown and start dev preview. |
pnpm run dev |
Start Vite dev server only |
pnpm run inject |
Inject resume into theme |
pnpm run generate |
Generate a styled PDF |
pnpm run image:png |
Export PNG of the resume |
pnpm run image:jpeg |
Export JPEG of the resume. |
pnpm run unocss:build |
Manually build UnoCSS styles |
pnpm install
# or
npm installpnpm run inject
pnpm run devOr simply:
pnpm startOpens Vite dev server at http://localhost:5173. Markdown changes reflect automatically with hot reload.
pnpm run generateGenerates resume.pdf with UnoCSS-styled layout.
pnpm run image:png
pnpm run image:jpegCreates resume.png or resume.jpeg with full-page rendering.
node index.js <markdown-file> <theme> <output-file> [format] [--serve]| Arg # | Description | Example |
|---|---|---|
| 1 | Markdown file path | resume.md |
| 2 | Theme name (without .html) |
index |
| 3 | Output file name (with extension) | resume.pdf |
| 4 | Format: pdf, png, or jpeg (optional) |
png |
| Flag | --serve — launches dev server |
# Live preview with hot reload
node index.js resume.md index --serve
# PDF export
node index.js resume.md index resume.pdf pdf
# PNG export
node index.js resume.md index resume.png png
# JPEG export
node index.js resume.md index resume.jpeg jpeg"scripts": {
"unocss:build": "unocss './**/*.{html,md,vue,js,ts}' -o dist/unocss.css",
"start": "npm run inject && vite",
"dev": "vite",
"build:theme": "vite build",
"inject": "node index.js resume.md index --serve",
"generate": "node index.js resume.md index resume.pdf",
"image:png": "node index.js resume.md index resume.png png",
"image:jpeg": "node index.js resume.md index resume.jpeg jpeg"
}# John Doe {.text-blue-700 .text-4xl .font-bold}
## 💼 Experience
### Software Engineer — TechCorp
*2020 – Present*
- Developed full-stack apps using React and Laravel
## 🎓 Education
**B.Sc. in Software Engineering**
University of Example — 2016–2020
## 🛠️ Skills
- JavaScript
- Node.js
- Git & GitHubYou can add Tailwind/UnoCSS utility classes using {}:
# My Name {.text-blue-700 .text-4xl .font-bold}Themes are located in the themes/ directory.
Each theme should have this placeholder:
<div id="resume">
{{content}}
</div>After injecting, this is replaced with your rendered Markdown.
UnoCSS is a fast, on-demand utility engine. You can use Tailwind-like classes directly:
## Projects {.text-xl .mb-4 .text-gray-600}UnoCSS scans:
themes/**/*.htmlresume.md
🔧 Configured via uno.config.js.
.
├── index.js
├── resume.md
├── README.md
├── themes/
│ └── index.html
├── commands/
│ ├── inject-markdown.js
│ ├── generate-pdf.js
│ └── generate-image.js
├── utils/
│ ├── helpers.js
│ └── template.js
├── uno.config.js
├── vite.config.js
-
Renders Markdown to HTML via
markdown-it. -
Injects into your theme (replaces
{{content}}). -
UnoCSS builds styles from
.md+.htmlusage. -
Puppeteer renders as:
- PDF (
page.pdf) - PNG/JPEG (
page.screenshot)
- PDF (
-
Restores original template after export.
Contributions welcome! 🙌
You can help by:
- 🌟 Star this repo
- 📝 Create issues or pull requests
- 🐛 Report bugs or request features
- 🎨 Add themes - Enhancing UnoCSS templates
- 🧠 Improve performance, structure, or features
- 📚 Write documentation
- 🐛 Fix bugs
MIT © Madhusha Prasad
Built with ❤️ using Node.js, Vite, UnoCSS, and markdown-it
