{"id":49222880,"url":"https://github.com/createchance/mdviewer","last_synced_at":"2026-04-26T09:03:03.680Z","repository":{"id":353069343,"uuid":"1217685246","full_name":"CreateChance/mdviewer","owner":"CreateChance","description":"Minimal Markdown Reader, built with Tauri.","archived":false,"fork":false,"pushed_at":"2026-04-24T03:27:11.000Z","size":1438,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-24T05:35:02.264Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CreateChance.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-04-22T05:55:06.000Z","updated_at":"2026-04-24T03:27:00.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/CreateChance/mdviewer","commit_stats":null,"previous_names":["createchance/mdviewer"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/CreateChance/mdviewer","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CreateChance%2Fmdviewer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CreateChance%2Fmdviewer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CreateChance%2Fmdviewer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CreateChance%2Fmdviewer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CreateChance","download_url":"https://codeload.github.com/CreateChance/mdviewer/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CreateChance%2Fmdviewer/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32291343,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-26T08:29:33.829Z","status":"ssl_error","status_checked_at":"2026-04-26T08:29:18.366Z","response_time":129,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-04-24T05:02:42.655Z","updated_at":"2026-04-26T09:03:03.661Z","avatar_url":"https://github.com/CreateChance.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# MD Viewer\n\nA minimal desktop Markdown reader built with Tauri + React + TypeScript.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"./screenshots/main.png\" alt=\"Screenshot\" width=\"720\" /\u003e\n\u003c/p\u003e\n\n## Features\n\n- **Markdown Rendering** — Powered by react-markdown with GFM support (tables, task lists, strikethrough, etc.) and Emoji\n- **Table of Contents** — Auto-generated TOC sidebar on the left with click-to-jump, scroll-aware highlighting, and drag-to-resize\n- **File Explorer** — Right-side file tree that recursively lists all Markdown files in a directory, with auto-refresh on filesystem changes\n- **Code Highlighting** — Syntax highlighting via highlight.js with automatic language detection\n- **Math Formulas** — KaTeX-based rendering for both inline and block math expressions\n- **Mermaid Diagrams** — Supports flowcharts, sequence diagrams, Gantt charts, and more\n- **Theme Switching** — Light / dark theme toggle with automatic preference persistence\n- **Live Reload** — Automatically refreshes preview when the file is modified externally\n- **Smart Link Navigation** — Relative `.md` links open within the app; external URLs open in the system browser\n- **Local Image Support** — Renders relative-path images embedded in Markdown via Tauri asset protocol\n\n## Tech Stack\n\n| Layer | Technology |\n|-------|------------|\n| Desktop Framework | [Tauri v1](https://v1.tauri.app/) |\n| Frontend | React 19 + TypeScript |\n| Build Tool | Vite 7 |\n| Markdown | react-markdown + remark-gfm + remark-math |\n| Code Highlighting | rehype-highlight + highlight.js |\n| Math | rehype-katex + KaTeX |\n| HTML Support | rehype-raw |\n| Diagrams | Mermaid |\n| File Watching | notify + notify-debouncer-mini |\n| Directory Scanning | walkdir |\n| Package Manager | pnpm |\n\n## Project Structure\n\n```\nmdviewer/\n├── index.html                    # Entry HTML\n├── package.json\n├── pnpm-workspace.yaml\n├── tsconfig.json                 # TypeScript config\n├── tsconfig.node.json            # Node-side TS config (for Vite)\n├── vite.config.ts                # Vite config\n├── public/                       # Static assets\n├── src/                          # Frontend source\n│   ├── main.tsx                  # App entry, global style imports\n│   ├── App.tsx                   # Root component, file handling \u0026 layout\n│   ├── components/\n│   │   ├── FileExplorer.tsx      # Right-side file tree browser\n│   │   ├── MarkdownRenderer.tsx  # Markdown rendering core (all plugins)\n│   │   ├── Mermaid.tsx           # Mermaid diagram component\n│   │   ├── Sidebar.tsx           # Left-side TOC navigation (drag-to-resize)\n│   │   └── Toolbar.tsx           # Top toolbar (open file/folder \u0026 theme toggle)\n│   ├── hooks/\n│   │   └── useTheme.ts          # Light/dark theme management\n│   └── styles/\n│       └── index.css            # Global styles \u0026 CSS variable themes\n└── src-tauri/                   # Tauri / Rust backend\n    ├── Cargo.toml               # Rust dependencies\n    ├── tauri.conf.json          # Tauri app config (window, permissions, etc.)\n    ├── build.rs                 # Tauri build script\n    ├── src/\n    │   └── main.rs              # Rust entry (file/dir watching, directory scan)\n    └── icons/                   # App icon assets\n```\n\n## Prerequisites\n\n- [Node.js](https://nodejs.org/) \u003e= 18\n- [pnpm](https://pnpm.io/) \u003e= 8\n- [Rust](https://www.rust-lang.org/tools/install) \u003e= 1.70\n- Tauri v1 system dependencies (see [Tauri Prerequisites](https://v1.tauri.app/v1/guides/getting-started/prerequisites))\n\n## Development\n\n```bash\n# Install frontend dependencies\npnpm install\n\n# Start development mode (launches Vite dev server + Tauri window)\npnpm tauri dev\n```\n\nIn development mode, frontend changes are hot-reloaded via Vite HMR, and Rust code changes trigger automatic recompilation.\n\nTo debug the frontend only (without the Tauri window):\n\n```bash\npnpm dev\n# Open http://localhost:1420 in your browser\n```\n\n## Build \u0026 Package\n\n```bash\n# Production build (frontend + Rust compilation + installer packaging)\npnpm tauri build\n```\n\nBuild artifacts are located at `src-tauri/target/release/bundle/`:\n\n| Platform | Output | Path |\n|----------|--------|------|\n| macOS | `.app` + `.dmg` | `bundle/macos/` and `bundle/dmg/` |\n| Windows | `.msi` + `.exe` | `bundle/msi/` and `bundle/nsis/` |\n| Linux | `.deb` + `.AppImage` | `bundle/deb/` and `bundle/appimage/` |\n\n### Cross-Compilation\n\nTauri builds for the current platform by default. For cross-compilation, add the corresponding Rust target:\n\n```bash\n# Example: Build for Apple Silicon on macOS\nrustup target add aarch64-apple-darwin\npnpm tauri build --target aarch64-apple-darwin\n\n# Example: Build for Intel on macOS\nrustup target add x86_64-apple-darwin\npnpm tauri build --target x86_64-apple-darwin\n\n# Build Universal Binary (Intel + Apple Silicon)\npnpm tauri build --target universal-apple-darwin\n```\n\n### Customization\n\nEdit the following fields in `src-tauri/tauri.conf.json`:\n\n- `package.productName` — Application name\n- `package.version` — Version number\n- `tauri.bundle.identifier` — Unique app identifier (e.g. `com.yourname.mdviewer`)\n- `tauri.bundle.icon` — App icons\n\n### CI/CD\n\nRefer to the official [Tauri GitHub Actions guide](https://v1.tauri.app/v1/guides/building/cross-platform) for multi-platform automated builds and releases.\n\n## Troubleshooting\n\n### macOS: \"mdviewer is damaged and can't be opened\"\n\nThis happens because the app is not signed with an Apple Developer certificate. macOS Gatekeeper blocks unsigned apps downloaded from the internet.\n\nTo fix, run in Terminal:\n\n```bash\n/usr/bin/xattr -cr /Applications/mdviewer.app\n```\n\nThen open the app again normally.\n\n## License\n\n[Apache License 2.0](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcreatechance%2Fmdviewer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcreatechance%2Fmdviewer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcreatechance%2Fmdviewer/lists"}