Skip to content
/ md Public

A fast, lightweight Markdown preview application built with Tauri 2, SolidJS, and Shiki.

Notifications You must be signed in to change notification settings

dnl-fm/md

Repository files navigation

MD Logo

MD

A fast, lightweight Markdown ecosystem: desktop app + browser extension.

Platform Browser License

Overview

MD is a markdown viewing ecosystem with two components:

Component Purpose
MD App Desktop application for local markdown files with full editing, print/PDF export
MD Extension Browser extension that renders raw .md URLs beautifully

Both share the same rendering engine, styles, and keyboard shortcuts.

Screenshots

Dark Theme    Light Theme


MD App (Desktop)

Features

  • Live Preview - Real-time markdown rendering with GitHub-flavored markdown support
  • Mermaid Diagrams - Native support for flowcharts, sequence diagrams, and more with theme-aware colors
  • ASCII Diagrams - Box-drawing character diagrams via WASM, same syntax as Mermaid but copy-pasteable
  • Syntax Highlighting - Code blocks with beautiful syntax highlighting powered by Shiki
  • Edit Mode - WASM-powered editor with language-aware syntax highlighting for 16+ languages
  • Table of Contents - Quick navigation panel with Ctrl+G, highlights current section
  • Scroll Sync - Position preserved when switching between edit and preview modes
  • In-Document Search - Find text with Ctrl+F, visual minimap for match locations
  • Draft Tabs - Create untitled drafts with Ctrl+N, auto-numbered for easy access
  • Themes - Dark and light themes with fully customizable colors
  • File Watching - Automatic reload when the file changes externally
  • Recent Files - Quick access to recently opened files with Ctrl+1-9
  • Customizable Fonts - Choose font family and size for both UI and markdown content
  • Resizable Sidebar - Drag to resize or double-click to auto-fit content
  • Print/PDF Export - Export documents with Ctrl+P using optimized print styles

Keyboard Shortcuts

Shortcut Action
Ctrl+O Open file
Ctrl+N New untitled draft
Ctrl+W Close file
Ctrl+S Save changes (in edit mode)
Ctrl+Z Undo (in edit mode)
Ctrl+Y Redo (in edit mode)
Ctrl+F Find in document
Ctrl+G Table of contents
Ctrl+P Print / Export PDF
Ctrl+L Toggle line numbers (in edit mode)
Ctrl+T Toggle theme (dark/light)
Ctrl+B Toggle sidebar
Ctrl+H Help
Ctrl+, Open settings
Ctrl++ Increase font size
Ctrl+- Decrease font size
Ctrl+0 Reset font size
Ctrl+1-9 Open Nth file/draft from sidebar
Ctrl+[/] Previous/next file
Ctrl+Space Toggle edit mode
Tab Indent line(s) (in edit mode)
Shift+Tab Dedent line(s) (in edit mode)
Esc Cancel edit / close search / discard changes

Installation

Pre-built Binaries

Download the latest release for your platform from the Releases page.

  • Linux: .deb, .rpm, or .AppImage
  • macOS: .dmg
  • Windows: .msi or .exe

Build from Source

# Clone the repository
git clone https://github.com/dnl-fm/md.git
cd md

# Install dependencies
bun install

# Development mode
make dev

# Build for production
make build

Configuration

Configuration is stored in:

  • Linux: ~/.config/com.fightbulc.md-preview/config.json
  • macOS: ~/Library/Application Support/com.fightbulc.md-preview/config.json
  • Windows: %APPDATA%\com.fightbulc.md-preview\config.json

MD Extension (Browser)

Features

  • Auto-Detection - Renders raw .md URLs from GitHub, GitLab, Gitea, and any plain text markdown
  • Reader Mode - Convert any webpage to clean markdown for distraction-free reading (press M)
  • Syntax Highlighting - Code blocks with Prism.js (bundled)
  • Mermaid Diagrams - Flowcharts, sequence diagrams, etc. (server-rendered)
  • ASCII Diagrams - Box-drawing diagrams, same syntax as Mermaid (server-rendered)
  • Table of Contents - Navigate long documents with Ctrl+G
  • Theme Support - Dark/light themes, follows system preference
  • Print/PDF - Export with Ctrl+P
  • Font Size - Adjustable with Ctrl++/-
  • Full Width - Toggle between constrained and full-width layout (default: on)
  • Persistent Settings - Theme, font size, width saved across all sites

Keyboard Shortcuts

Shortcut Action
M Reader mode (convert page to markdown)
Ctrl+G Table of contents
Ctrl+T Toggle theme
Ctrl+P Print / PDF
Ctrl++ Increase font size
Ctrl+- Decrease font size
Ctrl+0 Reset font size
Ctrl+H Help

Installation

Chrome Web Store

Install MD Extension

Load Unpacked (Development)

cd packages/extension
bun install
bun run build
  1. Open chrome://extensions (Chrome) or about:debugging (Firefox)
  2. Enable Developer mode
  3. Click "Load unpacked" and select packages/extension/dist

Supported URLs

  • *.md files served as text/plain
  • raw.githubusercontent.com/*
  • gist.githubusercontent.com/*
  • GitLab/Gitea raw file URLs
  • Any URL ending in .md or .markdown

Note: Local file:// URLs are not supported due to browser security restrictions. Use the MD desktop app for local markdown files.


Tech Stack

  • Tauri 2 - Native app framework
  • SolidJS - Reactive UI framework
  • Shiki - Syntax highlighting (app)
  • Prism.js - Syntax highlighting (extension)
  • markdown-it - Markdown parser
  • Mermaid - Diagram rendering
  • Vite - Build tool
  • Bun - JavaScript runtime & package manager

Project Structure

md/
├── packages/
│   ├── shared/       # Shared styles (CSS variables, markdown, print)
│   ├── app/          # Tauri desktop app (SolidJS + Rust)
│   └── extension/    # Chrome/Firefox extension
├── docs/             # Screenshots, plans, LLM docs
└── Makefile          # Development commands

License

MIT License - see LICENSE for details.

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

About

A fast, lightweight Markdown preview application built with Tauri 2, SolidJS, and Shiki.

Resources

Stars

Watchers

Forks

Packages

No packages published