A full-featured markdown editor available in two editions:
| Edition | Stack | Binary size | Runtime |
|---|---|---|---|
| Electron (this folder) | TypeScript + Node.js backend | ~150 MB | Bundled Chromium |
Tauri (tauri-app/) |
Rust backend + OS WebView | ~5–10 MB | WKWebView / WebView2 |
See tauri-app/README-Tauri.md for the Tauri edition.
- Full Markdown Support — Headers H1–H6, lists, code blocks, tables, footnotes, task lists
- Mermaid Diagrams — Flowcharts, sequences, class, state, ER, Gantt, pie — rendered locally (no CDN)
- Live Split-Pane Preview — Real-time rendering side-by-side with the editor
- Full Menu Bar — In-app dropdown menus: File / Edit / Paragraph / Format / View
- Native OS Menu — System menu bar with 30+ items and keyboard shortcuts
- File Operations — New, Open, Save, Save As, Export as self-contained HTML
- Three View Modes — Editor only, Preview only, or Split view
- Syntax Highlighting — Code blocks rendered via highlight.js (no CDN)
- Zoom Controls — 50%–200% zoom on editor and preview content
- macOS Native — Native menu bar, keyboard shortcuts, file dialogs
npm install
npm run devFor detailed setup: See Docs/Quickstart.md
| Shortcut | Action |
|---|---|
⌘N |
New file |
⌘O |
Open file |
⌘S |
Save |
⌘⇧S |
Save As |
⌘E |
Export as HTML |
⌘B |
Bold |
⌘I |
Italic |
⌘K |
Insert Link |
⌘1–⌘6 |
Heading 1–6 |
⌘⇧U |
Unordered list |
⌘⇧O |
Ordered list |
⌘⇧E |
Editor only |
⌘⇧P |
Preview only |
⌘⇧D |
Split view |
⌘+ / ⌘- |
Zoom in / out |
⌘/ |
Keyboard shortcuts |
⌘Q |
Quit |
npm install
chmod +x scripts/start.sh scripts/stop.sh# Development (hot-reload, DevTools open)
npm run dev
# Production
npm run build && npm start
# Detached via scripts
./scripts/start.sh # start (saves PID to .app.pid)
./scripts/stop.sh # stop gracefullynpm run dev # Development mode
npm run build # Production build
npm start # Run production build
npm run package:mac # Create .app / .dmg installer
npm test # Run 43 unit tests
npm run lint # ESLint checkAll diagram rendering happens locally — no internet connection required.
```mermaid
graph TD
A[Start] --> B[Process] --> C[End]
```Supported types: flowcharts, sequence, class, state, ER, Gantt, pie.
aam-markdown-editor/
├── src/
│ ├── main/ # Electron main process (Node.js/TypeScript)
│ ├── preload/ # Context bridge
│ ├── renderer/ # React UI (App.tsx, components/, styles/)
│ └── lib/ # Shared logic (applyAction.ts)
├── tauri-app/ # Tauri/Rust edition (see tauri-app/README-Tauri.md)
├── Docs/ # Architecture.md, Quickstart.md
├── scripts/ # start.sh, stop.sh, setup-Tauri.sh
└── README.md
- Electron 27, React 18, TypeScript 5
- Vite (bundler), markdown-it (renderer), Mermaid v10, highlight.js
- Lucide React icons, vitest (43 tests)
- Context isolation enabled, Node integration disabled in renderer
- IPC channel validation in preload
- No hardcoded secrets — use
.env(see.env.example)
Permission denied on scripts
chmod +x scripts/start.sh scripts/stop.sh scripts/setup-Tauri.shPort 3000 in use
lsof -ti:3000 | xargs kill -9Dependencies broken
rm -rf node_modules package-lock.json && npm installMermaid not rendering — open DevTools (⌘⌥I) and check the console for syntax errors in your diagram.
npm run build
npm run package:mac # produces dist/*.dmgMIT
See Docs/Quickstart.md for a step-by-step guide
See Docs/Architecture.md for technical diagrams
See tauri-app/README-Tauri.md for the Tauri/Rust edition