ngode-ngide kode ngadi-ngadi
Create beautiful images of your markdown with authentic OS window simulations, Fira Code ligatures, Mermaid diagrams, and KaTeX math formulas.
π Live Demo: sandikodev.github.io/snapcode
Features β’ Quick Start β’ Contributing β’ License
This project celebrates 10 years (2016-2026) in Computer Science, specializing in Web Technology.
A journey of passion, persistence, and pure love for the craftβdistilled into a comprehensive learning resource.
From SMK to 10 years of experience. From dropout to DevOps engineer. From struggle to mastery.
Not for profit, but for passion. Not for certificates, but for knowledge.
# Just open in browser - that's it!
open index.htmlNo npm, no build, no server needed! Pure client-side rendering.
π‘ Note: Python server (
server.py) is OPTIONAL - only for learning dynamic file loading.
The main app works 100% in browser without any server!
- macOS Sequoia - Latest macOS with gradient backdrop blur
- macOS Ventura - Classic macOS with traffic lights
- Windows 11 - Modern rounded corners with centered controls
- Windows 10 - Classic Windows with blue accent border
- Chrome OS - Material Design with circular buttons
- Dracula - Dark purple-gray theme
- Monokai - Classic dark brown theme
- GitHub - Clean light theme with proper syntax colors
- Nord - Arctic blue-gray theme
- β Fira Code Ligatures - Beautiful programming ligatures (=>, ===, !=, <=, etc)
- β Mermaid Diagrams - Flowcharts, sequence diagrams, and more
- β KaTeX Math - Inline and block mathematical formulas
- β Syntax Highlighting - Powered by Prism.js
- β Custom Scrollbars - OS-specific scrollbar styles
- β Watermark - Customizable size and opacity
- β Drag & Drop - Drop markdown files directly
- β Export PNG - High-quality 2x resolution
- β Copy Image - Copy to clipboard (Chrome/Edge)
SnapCode is 100% CLIENT-SIDE! No server required for main functionality.
- β Buildless - No npm, webpack, or build tools
- β Serverless - Runs entirely in browser
- β Componentless - No React/Vue/Svelte complexity
- β Single File - Just 56KB HTML file
- β CDN Dependencies - No node_modules bloat
The server.py is OPTIONAL and only for:
- π Learning dynamic file loading
- π Backend/DevOps study case
- π REST API concepts
Main app works perfectly without it!
π Read more: ARCHITECTURE.md
Visit sandikodev.github.io/snapcode and start creating!
# Clone or download index.html
# Open in browser - no build step required!
open index.htmlThat's it! No npm install, no build process, no dependencies to manage.
Type or paste your markdown content in the editor.
- Choose OS window style
- Select theme
- Adjust font size and padding
- Enable/disable Fira Code, Mermaid, KaTeX
- Add watermark
- Export PNG - Download high-quality image
- Copy Image - Copy to clipboard (paste in Paint, Photoshop, etc)
- Copy Text - Copy markdown source
const add = (a, b) => a + b;
if (x !== y && a >= b) {
console.log("Beautiful!");
}flowchart TD
A[Start] --> B{Decision?}
B -->|Yes| C[Success]
B -->|No| D[Retry]
Inline:
Block: $$ x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a} $$
- Alpine.js (15KB) - Reactive UI without build step
- Tailwind CSS (CDN) - Utility-first styling
- Marked.js - Markdown parsing
- DOMPurify - XSS protection
- Prism.js - Syntax highlighting
- Mermaid.js - Diagram rendering
- KaTeX - Math formula rendering
- html2canvas - PNG export
- Fira Code - Programming font with ligatures
- Buildless - No npm, no webpack, no vite
- Single HTML file - 52KB total
- CDN-based - All dependencies from CDN
- Progressive Enhancement - Works without JavaScript (basic markdown)
Range: 10-24px (default: 14px)
Range: 32-128px (default: 32px) Controls the space between window and desktop background.
- Custom text (default: @sandikodev)
- Size: 8-24px (default: 24px)
- Opacity: 10-100% (default: 30%)
Custom filename displayed in window title bar (default: README.md)
- β Markdown support (not just code)
- β Mermaid diagrams
- β KaTeX math formulas
- β Multiple OS simulations
- β Offline capable (single HTML file)
- β Open source
- β Authentic OS window simulations
- β Syntax highlighting
- β Customizable themes
- β High-quality export
- β No watermark (unless you want one)
sandikodev.github.io/snapcode/
βββ index.html # Complete app (52KB)
βββ README.md # This file
That's it! Single HTML file with everything included.
Just edit index.html and refresh browser.
- Alpine.js - Reactive state management
- CSS-in-JS - Dynamic theme styling
- Template Literals - Dynamic CSS generation
- ES6+ - Modern JavaScript
// Alpine.js component
function app() {
return {
// Reactive state
theme: 'dracula',
fontSize: 14,
// Computed properties
get parsedMarkdown() { ... },
get styles() { ... },
// Methods
exportImage() { ... },
copyText() { ... }
}
}Contributions are welcome! This is an open-source project built for the community.
- π¨ Features - New OS themes, color themes, export formats
- π Bug Fixes - Browser compatibility, rendering issues
- π Documentation - Improve clarity, add examples, translations
- π‘ Ideas - Suggest features, share use cases
Since this is a single HTML file, contributing is easy:
- Fork the repository
- Edit
index.htmlin your browser or editor - Test by opening in browser (no build needed!)
- Submit a Pull Request
See CONTRIBUTING.md for detailed guidelines.
We follow a Code of Conduct to ensure a welcoming environment for all contributors.
MIT License - feel free to use for personal or commercial projects.
@sandikodev
- Website: sandikodev.github.io/snapcode
- Twitter: @sandikodev
- Alpine.js - Caleb Porzio
- Tailwind CSS - Adam Wathan
- Prism.js - Lea Verou
- Mermaid.js - Knut Sveidqvist
- KaTeX - Khan Academy
- Fira Code - Nikita Prokopov
- File Size: 52KB (single HTML file)
- Dependencies: 0 (all from CDN)
- Build Time: 0 seconds (buildless)
- Load Time: < 1 second
- Browser Support: Modern browsers (Chrome, Firefox, Safari, Edge)
- More OS themes (Ubuntu, Fedora)
- Custom color themes
- SVG export
- Share via URL
- Dark mode for UI
- Keyboard shortcuts
- More diagram types
- Animation support
- π Documentation - Beautiful code examples
- π Education - Teaching materials with diagrams
- π± Social Media - Share code snippets
- π Blog Posts - Code screenshots
- π¨ Presentations - Professional slides
- π Books - Technical illustrations
- First Load: < 1s (with CDN cache)
- Render Time: < 100ms
- Export Time: 1-2s (depending on content)
- Memory Usage: < 50MB
- Bundle Size: 52KB (uncompressed)
- β No tracking
- β No analytics
- β No cookies
- β No server-side processing
- β Everything runs locally in your browser
- β Your content never leaves your device
| Browser | Version | Status |
|---|---|---|
| Chrome | 90+ | β Full support |
| Firefox | 88+ | β Full support |
| Safari | 14+ | β Full support |
| Edge | 90+ | β Full support |
| Opera | 76+ | β Full support |
- π Bug Reports: GitHub Issues
- π¬ Discussions: GitHub Discussions
- π§ Email: hello@sandikodev.com
- π¦ Twitter: @sandikodev
Made with β€οΈ by @sandikodev
ngode-ngide kode ngadi-ngadi π