This file provides high-level guidance for Claude when working with this repository.
For detailed project documentation, see AGENTS.md.
MermZen - A clean, lightweight Mermaid diagram editor with hand-drawn style support.
- Live Demo: https://eric.run.place/MermZen/
- Tech Stack: Vite 7 + TypeScript + Mermaid 11 + CodeMirror 6
- Deployment: GitHub Pages (auto-deploy on push to main)
# Development
npm run dev # Start dev server (port 5173)
npm run type-check # TypeScript check
# Build
npm run build # Production build (dist/)
npm run build:all # Build + screenshots + blog
npm run build:screenshots # Generate README screenshots
# Test
npx playwright test test-tour.spec.js- Source code: All TypeScript source is in
src/modules/ - Old JS files: The root
modules/directory was deleted after TS migration - Scripts: Build/utility scripts are in
scripts/directory - Agent Skill:
skills/mermzen-render/— open-standard Agent Skill (agentskills.io), installable vianpx skills add caoergou/MermZen - Blog: Static blog in
blog/directory - SEO / sitemap:
scripts/generate-sitemap.shbuildssitemap.xmlby scanning the repo for*.html. It MUST excludenode_modules/,dist/and other artifact dirs — otherwise third-party demo pages (e.g.cytoscape-fcose/demo/*.html,tslib/*.html) get listed in the sitemap and crawled by Google, which 404s them in Search Console (onlydist/is deployed, so those paths don't exist on the live site). When adding a new build/output dir, add it to thefind ... -not -pathexcludes too. See commit391a65e. Bothsitemap.xmlandrobots.txtare gitignored and regenerated at deploy.
| File | Purpose |
|---|---|
index.html |
Main app page |
embed.html |
Embedded diagram viewer |
src/app.ts |
Main entry point |
src/embed.ts |
Embed page entry point |
vite.config.ts |
Build configuration |
?skipTour=1- Skip onboarding tour?lang=zh|en- Set language
📖 See AGENTS.md for complete documentation including:
- Full architecture overview
- Module descriptions
- Development guidelines
- Testing instructions