Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
ilteoood avatar

Drawio

  • 218 installs
  • 2 repo stars
  • Updated July 24, 2026
  • ilteoood/harness

Render.drawio architecture diagrams to PNG for READMEs, specs, and agent context using CLI or headless viewer fallbacks.

About

drawio is a harness-embedded agent skill oriented around turning diagrams.net sources into PNGs that solo builders can drop into repos, PRs, or spec folders. The documented script prioritizes fidelity: use the native draw.io CLI when installed for speed and accuracy, otherwise load the official viewer in a headless browser so orthogonal connectors and container layouts match what authors see in the editor. Batch mode walks directories so a single command refreshes every architecture sheet before a release note or onboarding doc update. For agentic workflows, that means Mermaid-like convenience but with full draw.io expressiveness—provided you accept Node tooling and optional network fetches for the viewer assets. It complements markdown prose rather than replacing diagram authoring; you still maintain .drawio files as the source of truth.

  • drawio-to-png.mjs converts single files or whole directories of .drawio sources
  • Three renderer modes: draw.io CLI, official viewer in headless browser, and auto selection
  • Official draw.io viewer JS path for pixel-perfect edges and shape routing when CLI is missing
  • Supports compressed diagram payloads via zlib inflate before render
  • Puppeteer-core drives headless rendering when network-backed viewer is required

Drawio by the numbers

  • 218 all-time installs (skills.sh)
  • +30 installs in the week ending Jul 25, 2026 (Skillselion tracking)
  • Ranked #505 of 1,901 Documentation skills by installs in the Skillselion catalog
  • Security screen: MEDIUM risk (skills.sh audit)
  • Data as of Jul 25, 2026 (Skillselion catalog sync)
npx skills add https://github.com/ilteoood/harness --skill drawio

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs218
repo stars2
Security audit2 / 3 scanners passed
Last updatedJuly 24, 2026
Repositoryilteoood/harness

What it does

Render.drawio architecture diagrams to PNG for READMEs, specs, and agent context using CLI or headless viewer fallbacks.

Files

SKILL.mdMarkdownGitHub ↗

Draw.io Diagram Skill

Generate draw.io diagrams as native .drawio files and export them to PNG images that can be embedded in Word documents.

How to Create a Diagram

1. Generate draw.io XML in mxGraphModel format for the requested diagram 2. Write the XML to a .drawio file using the create/edit file tool 3. Export to PNG using the bundled export script

Bundled Export Script

This skill includes drawio-to-png.mjs, a Node.js export script with two rendering backends:

1. draw.io CLI (pixel-perfect, fastest) — used automatically if draw.io desktop is installed 2. Official draw.io viewer in headless browser (pixel-perfect, needs Chromium/Edge) — fallback when CLI is unavailable

Usage

# Install dependencies (one-time, from the scripts folder)
cd skills/drawio/scripts && npm install

# Export a single diagram
node skills/drawio/scripts/drawio-to-png.mjs <input.drawio> [output.png]

# Export all .drawio files in a directory
node skills/drawio/scripts/drawio-to-png.mjs --dir <directory>

# Force a specific renderer
node skills/drawio/scripts/drawio-to-png.mjs --renderer=cli|viewer|auto <input.drawio>

Skill Folder Contents

FilePurpose
SKILL.mdThis instruction file
scripts/drawio-to-png.mjsNode.js export script (CLI + browser fallback)
scripts/package.jsonDependencies (puppeteer-core)

Supported Export Formats

FormatEmbed XMLNotes
pngYesViewable everywhere, editable in draw.io
svgYesScalable, editable in draw.io
pdfYesPrintable, editable in draw.io

Draw.io XML Style Conventions

Use these styles for consistent, professional diagrams:

<!-- Primary service (highlighted) -->
<mxCell style="rounded=1;whiteSpace=wrap;html=1;fillColor=#dae8fc;strokeColor=#6c8ebf;strokeWidth=2;arcSize=12;shadow=1;" />

<!-- External system -->
<mxCell style="rounded=1;whiteSpace=wrap;html=1;fillColor=#f5f5f5;strokeColor=#666666;" />

<!-- Success/processing stage -->
<mxCell style="rounded=1;whiteSpace=wrap;html=1;fillColor=#d5e8d4;strokeColor=#82b366;" />

<!-- Warning/quality gate -->
<mxCell style="rounded=1;whiteSpace=wrap;html=1;fillColor=#fff2cc;strokeColor=#d6b656;" />

<!-- Error/failure path -->
<mxCell style="rounded=1;whiteSpace=wrap;html=1;fillColor=#f8cecc;strokeColor=#b85450;" />

<!-- Data store (cylinder) -->
<mxCell style="shape=cylinder3;whiteSpace=wrap;html=1;fillColor=#fff2cc;strokeColor=#d6b656;" />

<!-- Arrow -->
<mxCell style="edgeStyle=orthogonalEdgeStyle;rounded=1;strokeColor=#6c8ebf;strokeWidth=2;" />

Locating the draw.io CLI

Try drawio first (works if on PATH), then fall back:

  • Windows: "C:\Program Files\draw.io\draw.io.exe"
  • macOS: /Applications/draw.io.app/Contents/MacOS/draw.io
  • Linux: drawio (via snap/apt/flatpak)

CLI Export Command

drawio -x -f png -e -b 10 -o <output.png> <input.drawio>

Flags: -x (export), -f (format), -e (embed diagram XML), -b (border), -o (output path).

Related skills

Forks & variants (1)

Drawio has 1 known copy in the catalog totaling 1 installs. They canonicalize to this original listing.

FAQ

Is Drawio safe to install?

skills.sh reports 2 of 3 security scanners passed. Review the Security Audits panel on this page before installing in production.

Documentationdocsdevops

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.