# How to redraw an old Mermaid or draw.io diagram in a cleaner style with diagram-design

Repo: [cathrynlavery/diagram-design](https://github.com/cathrynlavery/diagram-design) | Difficulty: Intermediate | Time: 30 minutes | Basis: From the README

Import an existing Mermaid, draw.io or Excalidraw file and get it back as a polished editorial diagram.

**Who it is for:** Docs maintainer with a folder of ugly Mermaid or draw.io diagrams in their README and wiki

**The problem:** Existing diagrams use default theme styling that looks dated and inconsistent across pages.

**The outcome:** The same diagrams redrawn in one consistent editorial style, exported as PNG or SVG for the docs.

## Steps

1. Install the skill with: npx skills add cathrynlavery/diagram-design
2. Hand your agent the Mermaid, draw.io or Excalidraw source and ask it to redraw it with the skill.
3. Open the new HTML file and check that every node and edge from the original survived.
4. Export to PNG or SVG and replace the old image in your docs.

## Prompt to paste into your agent

```text
Use the diagram-design skill to import <path to mermaid, drawio or excalidraw file> and redraw it as a clean HTML and SVG diagram. Confirm that the node and edge counts match the original and export an SVG.
```

## Caveat

Import is described in the README, but complex layouts may be re-arranged by the skill, so compare the result against the original instead of assuming it is identical.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/cathrynlavery-diagram-design/replace-mermaid-diagrams-with-cleaner-ones/
