Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
035f46b
feat: ship a command reference for the docs
maielo Nov 3, 2026
fccdbfd
feat: SVG and per-frame rendering, Mermaid conversion, scene sharing,…
maielo Nov 3, 2026
fd7a68c
fix: keep the render browser off the user's proxy
maielo Nov 3, 2026
2006256
feat: identify the CLI to the API with its User-Agent
maielo Nov 3, 2026
e7c14ac
fix: read proxy settings as curl does, and skip ones the CLI can't use
maielo Nov 5, 2026
cca6ee1
fix: valid, clipped frame SVGs, and renders that fail fast and stream…
maielo Nov 5, 2026
da0bb2b
feat: show that render and mermaid need no account, and a clearer login
maielo Nov 5, 2026
d1f94f6
feat: editable Gantt charts, quadrant charts and timelines from Mermaid
maielo Nov 5, 2026
2e75c5e
fix: keep subcommands' help commands out of the top-level command groups
maielo Nov 5, 2026
8aeaed5
feat: a login screen that shows what's free next to what Excalidraw+ …
maielo Nov 5, 2026
28074fe
chore: drop the release-age exemption for mermaid-to-excalidraw 3.4.0
maielo Nov 6, 2026
0081ed5
docs: a guide for writing pull request notes
maielo Nov 6, 2026
194ea4d
docs: a README banner, rendered from an HTML source with the CLI's ow…
maielo Nov 6, 2026
55d1807
docs: move the guides into docs/ and ship them in the package for the…
maielo Nov 6, 2026
e6a2e18
docs: a short README with a banner, features, install, quick start an…
maielo Nov 6, 2026
a48723b
fix: load the bundled fonts even when a system font has the same name
dwelle Nov 6, 2026
2fa8059
feat: PNGs as big as --scale asks, with a warning when a limit shrink…
maielo Nov 6, 2026
a5ae26d
feat: help laid out like the login screen
maielo Nov 6, 2026
ab11c09
docs: keep the important notes in the help, the rest in docs/
maielo Nov 6, 2026
74a6ff2
docs: the help says how to change an element, what --out - writes, an…
maielo Nov 6, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 52 additions & 0 deletions .github/PULL_REQUEST_GUIDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Writing pull request notes

Notes are for a reviewer who has a minute. Keep them short, in bullets, and about what changes for users. Whoever writes them, person or agent, follows this file.

## Title

Like the commit messages: `feat: …`, `fix: …` or `chore: …`, then what the change does in plain words.

## Body

Use these sections in this order. Leave out any that would be empty.

```markdown
One sentence: what the PR is for.

## What's new
- `command --flag`: what it does for the user.

## Fixes
- What was wrong, in user terms, and that it's fixed.

## Screenshots
| What it shows | What it shows |
| --- | --- |
| ![alt text](url) | ![alt text](url) |

## Notes
- Only what a reviewer needs to know or decide: new dependencies, package size, follow-ups, known limits.

## Testing
- `pnpm run test`: N/N. `pnpm run test:render` (Chrome): N/N.
- What was checked by hand, and what wasn't tested.
```

## Rules

- One line per bullet. Start with the command, flag or file in backticks, then the effect.
- Say what users see, not how the code does it. Add implementation detail only when a reviewer has to check it.
- No more than about 10 bullets per section. Merge small related changes into one bullet.
- Numbers instead of adjectives: test counts, file sizes, versions.
- Say what didn't run or wasn't tested, such as live API tests skipped in CI.
- Describe the PR as a whole. When new commits land, rewrite the notes to match; don't append a log of pushes.

## Screenshots

Add one for anything users see: terminal screens (login, help, errors) and rendered output (PNG, SVG, Mermaid).

- Render images with the CLI itself at `--scale 2`, from small example files with neutral content.
- For terminal screens, capture the real output of the built CLI (`dist/main.js`) in color, not a mockup.
- Show before and after for a visible fix. When the difference doesn't show in an image, describe it in Fixes instead.
- Host the images outside the repo, for example in a GitHub gist: clone the gist, add the PNGs, push, and link `https://gist.githubusercontent.com/<user>/<gist-id>/raw/<file>.png`.
- Put them in a two-column table with a short caption above each image.
Binary file added .github/assets/banner-dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added .github/assets/banner-light.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added .github/assets/banner/Excalifont.woff2
Binary file not shown.
Binary file added .github/assets/banner/flow-dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added .github/assets/banner/flow-light.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 13 additions & 0 deletions .github/assets/banner/flow.mmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
flowchart LR
A[".excalidraw"] --> C(["excalidraw"])
B["Mermaid"] --> C
C --> P["PNG"]
C --> S["SVG"]
C --> F["Slides"]
C --> X["Excalidraw+"]
classDef cli fill:#d0bfff,stroke:#6965db,color:#1e1e1e
classDef out fill:#b2f2bb,stroke:#2f9e44,color:#1e1e1e
classDef in fill:#a5d8ff,stroke:#1971c2,color:#1e1e1e
class C cli
class P,S,F,X out
class A,B in
Binary file not shown.
Binary file not shown.
92 changes: 92 additions & 0 deletions .github/assets/banner/hero.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
<!doctype html>
<meta charset="utf-8" />
<title>Excalidraw CLI banner</title>
<style>
@font-face { font-family: "Geist"; src: url("geist-latin-wght-normal.woff2") format("woff2"); font-weight: 100 900; }
@font-face { font-family: "Geist Mono"; src: url("geist-mono-latin-wght-normal.woff2") format("woff2"); font-weight: 100 900; }
@font-face { font-family: "Excalifont"; src: url("Excalifont.woff2") format("woff2"); }

:root {
--bg: #fbfbfd; --dots: #dcdce6; --fg: #17171c; --muted: #6b6b7b; --card: #ffffff;
--border: #e6e6ee; --primary: #6965db; --primary-soft: #ecebfd; --glow: rgba(105, 101, 219, 0.26);
--glow-2: rgba(32, 201, 151, 0.1); --shadow: 0 1px 2px rgba(20, 20, 40, 0.06), 0 18px 48px -12px rgba(40, 36, 120, 0.28);
}
.dark {
--bg: #0e0e12; --dots: #24242c; --fg: #f4f4f7; --muted: #a1a1b0; --card: #18181d;
--border: rgba(255, 255, 255, 0.09); --primary: #9b97f5; --primary-soft: rgba(155, 151, 245, 0.14);
--glow: rgba(105, 101, 219, 0.38); --glow-2: rgba(32, 201, 151, 0.12);
--shadow: 0 1px 2px rgba(0, 0, 0, 0.5), 0 24px 60px -12px rgba(0, 0, 0, 0.7);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: "Geist", system-ui, sans-serif; -webkit-font-smoothing: antialiased; }

.hero {
position: relative; width: 1280px; height: 600px; overflow: hidden; border-radius: 18px; color: var(--fg);
background:
radial-gradient(560px 460px at 76% 52%, var(--glow), transparent 72%),
radial-gradient(480px 320px at 4% 100%, var(--glow-2), transparent 70%),
radial-gradient(circle, var(--dots) 1.2px, transparent 1.4px) 0 0 / 22px 22px,
var(--bg);
}

.left { position: absolute; left: 72px; top: 0; bottom: 0; width: 540px; display: flex; flex-direction: column; justify-content: center; }
.logo { width: 54px; height: 54px; flex: none; margin-right: 16px; transform: translateY(2px); }
h1 { margin: 0; display: flex; align-items: center; font-size: 58px; line-height: 1; font-weight: 650; letter-spacing: -0.04em; white-space: nowrap; }
.hand { position: relative; display: inline-block; margin-left: 15px; font-family: "Excalifont"; font-weight: 400; color: var(--primary); letter-spacing: 0; font-size: 66px; }
.hand svg { position: absolute; left: -6px; bottom: -14px; width: calc(100% + 12px); height: 18px; overflow: visible; }
.sub { margin: 28px 0 0; font-size: 22px; line-height: 1.4; color: var(--muted); letter-spacing: -0.01em; }

.arrow { position: absolute; inset: 0; width: 1280px; height: 600px; color: var(--primary); pointer-events: none; }

.canvas {
position: absolute; right: 56px; top: 34px; width: 440px; padding: 12px; border-radius: 16px;
background: var(--card); border: 1px solid var(--border); box-shadow: var(--shadow); transform: rotate(2.5deg);
}
.canvas img { display: block; width: 100%; border-radius: 8px; }

.term {
position: absolute; left: 606px; top: 316px; width: 560px; border-radius: 14px; overflow: hidden;
background: #15151b; border: 1px solid rgba(255, 255, 255, 0.08); box-shadow: 0 30px 70px -18px rgba(10, 8, 40, 0.55);
font-family: "Geist Mono", monospace; font-size: 13.5px; line-height: 1.6; color: #e6e6ef;
}
.bar { display: flex; align-items: center; gap: 7px; padding: 10px 14px; background: #1c1c24; border-bottom: 1px solid rgba(255, 255, 255, 0.06); }
.bar i { width: 11px; height: 11px; border-radius: 50%; }
.bar span { margin-left: 10px; font-size: 12px; color: #8b8b9c; font-family: "Geist", sans-serif; }
pre { margin: 0; padding: 14px 18px 16px; font: inherit; white-space: pre; }
.pr { color: #9b97f5; } .fl { color: #7dd3c0; } .k { color: #b7b4fa; } .s { color: #a6e3a1; } .n { color: #fab387; } .d { color: #6e6e80; }
</style>

<div class="hero" id="hero">
<div class="left">
<h1><svg class="logo" viewBox="0 0 32 32" fill="none"><path d="M31.818 26.31c-.067-.043-.133-.066-.222-.043-1.664-2.467-3.794-4.8-5.835-7.067l-.333-.378a.17.17 0 0 0-.045-.111.463.463 0 0 0-.133-.089l-.066-.067-.045-.044c-.066-.133-.222-.222-.377-.133-.621.31-1.198.777-1.753 1.222-.732.578-1.464 1.155-2.152 1.8a6.715 6.715 0 0 0-.777.822c-.11.156-.022.289.111.356a93.39 93.39 0 0 0-1.464 1.489.252.252 0 0 0-.067.177c0 .067.044.134.089.156l.865.667v.022c1.22 1.222 3.373 2.889 5.658 4.689.333.266.688.533 1.021.8.155.177.31.377.444.555a.238.238 0 0 0 .31.045c.045.044.111.088.156.133.044.022.089.044.133.044a.202.202 0 0 0 .178-.088.316.316 0 0 0 .044-.134c.022 0 .022.022.044.022a.252.252 0 0 0 .178-.066l4.038-4.422a.248.248 0 0 0 0-.356Zm-11.627-1.532c.022.044.045.066.089.11.466.4.954.8 1.464 1.245l-2.041-1.555-.2-.134c-.044-.022-.088-.066-.133-.089l-.155-.133.044-.044.045-.045.088-.089a234.53 234.53 0 0 1 2.463-2.422c-.643.645-1.93 2.533-1.664 3.156Zm6.967 5.51L25.472 29a35.632 35.632 0 0 0-2.086-2c.91.689 1.687 1.289 1.798 1.4.887.778.843.644 1.442 1.155l.732.534a.846.846 0 0 1-.2.2Zm.444.334-.044-.022c.066-.045.133-.09.2-.156l-.156.178ZM.976 4.6c.044.29.11.578.155.845.266 1.466.533 2.8 1.02 3.8l.2.755c.067.29.178.645.289.734 1.132 1 2.862 2.489 4.726 3.91.089.067.2.067.289 0 0 0 0 .023.022.023a.201.201 0 0 0 .155.067.252.252 0 0 0 .178-.067c2.374-2.644 4.149-4.822 5.414-6.644.088-.09.11-.223.11-.334.09-.089.156-.2.245-.266.088-.09.088-.245 0-.312l-.022-.022c0-.044-.023-.11-.067-.133-.555-.533-.954-.911-1.376-1.311-.732-.69-1.486-1.4-3.084-3l-.022-.022c-.022-.023-.045-.045-.089-.045-.444-.155-1.353-.311-2.485-.511C4.948 1.778 2.662 1.378.599.756c0 0-.134 0-.156.022L.377.845C.355.867.332.889.199.934h.045-.045c.022.133.022.222.067.377 0 .045.089.4.089.445L.975 4.6ZM13.29 7.223l-.267-.267c.067.089.156.155.267.267Zm-2.818 3.733-.045.044c0-.022.022-.044.045-.044Zm-1.62-8c.133.133.688.667.82.778-.576-.267-2.018-.934-2.684-1.156.666.133 1.575.267 1.864.378Zm-7.61-1.111c.332.578.598 2.578.864 4.533-.155-.622-.266-1.244-.399-1.822-.2-1.022-.4-1.933-.666-2.733.045 0 .111 0 .2.022Zm-.134-.467c-.089 0-.178-.022-.244-.022 0-.022 0-.045-.022-.045.11 0 .177.023.266.067Zm-.865.178c0-.022 0-.022 0 0ZM31.463 1.067c.023-.089-.443-.489-.288-.511.333-.022.333-.534 0-.534-.444.023-.91.134-1.331.2-.777.156-1.576.312-2.352.49a104.59 104.59 0 0 0-5.215 1.244c-.532.155-1.131.266-1.642.533-.177.089-.155.267-.066.378-.045.022-.067.022-.111.044-.155.023-.289.045-.444.067-.133.022-.2.133-.177.267 0 .022.022.066.022.089a138.091 138.091 0 0 1-3.107 3.955c-1.11 1.289-2.285 2.645-3.461 4.045-3.75 4.4-7.988 9.4-12.67 13.8a.215.215 0 0 0 0 .31c.022.023.044.045.067.045-.067.067-.134.111-.2.178-.044.044-.067.089-.067.133-.022.023-.066.067-.088.111-.09.09-.09.245.022.311.089.09.244.09.31-.022.023-.022.023-.044.045-.044a.348.348 0 0 1 .488 0c.266.289.532.578.777.822l-.555-.467c-.089-.088-.244-.066-.31.023-.09.088-.067.244.021.31L7.034 31.8c.044.045.088.045.155.045.066 0 .11-.022.155-.067l.133-.133c.023.022.067.022.09.022.066 0 .11-.022.154-.067 7.988-8.044 14.423-14.11 21.79-19.533.066-.044.088-.133.088-.2.09 0 .156-.067.2-.156 1.354-4.155 1.62-7.844 1.709-9.666v-.023c0-.022.022-.044.022-.066.022-.045.022-.067.022-.067a1.309 1.309 0 0 0-.089-.822ZM17.173 7.6c.356-.4.71-.822 1.066-1.2-2.286 3.022-6.08 7.667-11.45 13.2 3.662-4.066 7.345-8.266 10.385-12ZM4.239 28.622h.066-.066Zm2.751 2.556c-.022-.022-.022-.022 0-.022v.022Zm3.306-2.867c.178-.2.355-.377.555-.577 0 0 0 .022.022.022-.2.178-.377.355-.577.555Zm.91-.889c.111-.11.222-.266.355-.4l.022-.022a346.331 346.331 0 0 1 4.039-4.089l.022-.022c.333-.267.732-.555 1.087-.822a301.53 301.53 0 0 0-5.525 5.355Zm8.61-22.244c-.733.956-1.554 2.222-2.242 3.222-2.174 3.156-9.164 10.867-9.319 11a1572.044 1572.044 0 0 1-6.39 6.111l-.134.134c-.11-.134-.11-.334.023-.445 9.874-9.31 15.865-17.066 18.283-20.466-.066.155-.11.288-.222.444Zm3.838 4.556c-.888-.512-1.31-1.312-1.065-2.09l.066-.266c.023-.067.067-.156.111-.222.244-.4.6-.734.999-.934.022 0 .044 0 .067-.022-.023-.044-.023-.11-.023-.178.023-.133.111-.222.267-.222.266 0 1.087.245 1.397.511.09.067.178.156.267.245.11.133.288.355.377.533.044.022.089.245.155.356.045.177.089.377.067.555-.022.022 0 .156-.022.156a2.143 2.143 0 0 1-.289.822c-.022.022-.022.044-.044.067l-.022.022a1.617 1.617 0 0 1-.422.444c-.51.356-1.087.467-1.664.311 0 0-.155-.066-.222-.088Zm6.48-.667c-.2.822-.422 1.667-.711 2.533 0 .023-.022.067 0 .09-.044 0-.067.021-.11.044-1.754 1.289-3.462 2.644-5.17 4.022 1.464-1.311 2.928-2.645 4.46-3.956.443-.4.753-.91.842-1.489l.222-1.333v-.044c.111-.267.533-.156.466.133Z" fill="#6965DB"/></svg><span>Excalidraw</span> <span class="hand">CLI<svg viewBox="0 0 200 18" preserveAspectRatio="none"><path d="M3 11 C 40 4, 80 15, 120 8 S 180 6, 197 10" fill="none" stroke="currentColor" stroke-width="4" stroke-linecap="round"/></svg></span></h1>
<p class="sub">Render, convert and share, from your terminal.</p>
</div>

<svg class="arrow" viewBox="0 0 1280 600" fill="none" stroke="currentColor" stroke-width="2.6" stroke-linecap="round" stroke-linejoin="round">
<path d="M664 300 C 650 236, 700 186, 768 182" />
<path d="M666 302 C 653 240, 702 189, 769 184" opacity="0.55" />
<path d="M750 168 L 770 182 L 751 197" />
</svg>

<div class="canvas"><img id="diagram" alt="" /></div>

<div class="term">
<div class="bar"><i style="background:#ff5f57"></i><i style="background:#febc2e"></i><i style="background:#28c840"></i><span>/tmp/work</span></div>
<pre><span class="pr">$</span> excalidraw mermaid flow.mmd <span class="fl">--out</span> flow.svg
<span class="d">{</span>
<span class="k">"path"</span>: <span class="s">"/tmp/work/flow.svg"</span>,
<span class="k">"mimeType"</span>: <span class="s">"image/svg+xml"</span>,
<span class="k">"width"</span>: <span class="n">626.26</span>,
<span class="k">"height"</span>: <span class="n">436</span>
<span class="d">}</span>
<span class="pr">$</span> excalidraw render deck.excalidraw <span class="fl">--all-frames --out</span> slides/</pre>
</div>
</div>

<script>
const theme = new URLSearchParams(location.search).get("theme") || "light";
document.documentElement.classList.toggle("dark", theme === "dark");
document.getElementById("diagram").src = `flow-${theme}.png`;
</script>
22 changes: 22 additions & 0 deletions .github/assets/banner/render.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// Renders the README banner, hero.html, to ../banner-light.png and ../banner-dark.png.
// Fonts: Geist and Geist Mono (Vercel) and Excalifont (Excalidraw), all under the SIL Open Font License 1.1.
// The diagram in it comes from flow.mmd:
// excalidraw mermaid flow.mmd --out flow-light.png --scale 2 --padding 24 --theme light
// (and again with --theme dark). The terminal shows the real output of
// "excalidraw mermaid flow.mmd --out flow.svg" run in /tmp/work; update it when the output changes.
// Run with: node .github/assets/banner/render.mjs
import { fileURLToPath } from "node:url";
import { chromium } from "playwright-core";

const here = new URL(".", import.meta.url);
const browser = await chromium.launch({
executablePath: process.env.EXCALIDRAW_BROWSER_PATH ?? "/opt/google/chrome/chrome",
});
const page = await browser.newPage({ deviceScaleFactor: 1.5, viewport: { width: 1280, height: 600 } });
for (const theme of ["light", "dark"]) {
await page.goto(new URL(`hero.html?theme=${theme}`, here).href);
await page.evaluate(() => document.fonts.ready);
await page.waitForFunction(() => document.getElementById("diagram").complete);
await page.locator("#hero").screenshot({ path: fileURLToPath(new URL(`../banner-${theme}.png`, here)), omitBackground: true });
}
await browser.close();
14 changes: 11 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,13 @@ pnpm run build # typecheck src/, then bundle it into dist/
pnpm run typecheck # typecheck src/ and test/
```

esbuild bundles `src/` with chalk, commander and zod into `dist/main.js` plus lazily loaded chunks, so playwright-core is the only runtime dependency. Keep those libraries in `devDependencies`. playwright-core is pinned to an exact version because it drives whatever Chrome the user has installed; bump it on purpose and run `pnpm run test:render` before releasing. The build also turns the prebuilt browser bundle from `@excalidraw/utils` into `dist/renderer.js` (see `scripts/build-renderer.mjs`), so users don't install the whole package. Its inlined fonts become files in `dist/fonts/` that the browser requests only when a scene needs them, and the font-subsetting WebAssembly, which only SVG export uses, is dropped. Xiaolai, the 13 MB CJK font, doesn't ship: `dist/fonts/remote.json` lists its files, which the CLI downloads from CDN mirrors on first use, checks against their sha256, and caches. `scripts/fonts.json` identifies each font by sha256 and gives its path in the `@excalidraw/excalidraw` release the mirrors serve.
esbuild bundles `src/` with chalk, commander and zod into `dist/main.js` plus lazily loaded chunks, so playwright-core is the only runtime dependency. Keep those libraries in `devDependencies`. playwright-core is pinned to an exact version because it drives whatever Chrome the user has installed; bump it on purpose and run `pnpm run test:render` before releasing. The build also turns the prebuilt browser bundle from `@excalidraw/utils` into `dist/renderer.js` (see `scripts/build-renderer.mjs`), so users don't install the whole package. Its inlined fonts become files in `dist/fonts/` that the browser requests only when a scene needs them, and the font-subsetting WebAssembly, which only SVG export uses, becomes base64 text in `dist/wasm/`, loaded only for SVGs. Xiaolai, the 13 MB CJK font, doesn't ship: `dist/fonts/remote.json` lists its files, which the CLI downloads from CDN mirrors on first use, checks against their sha256, and caches. `scripts/fonts.json` identifies each font by sha256 and gives its path in the `@excalidraw/excalidraw` release the mirrors serve.

To update the renderer, bump its pinned version in `devDependencies`, run `node scripts/update-fonts.mjs @excalidraw/excalidraw@<version>` with a release that ships the same fonts, and rebuild. The build fails if the bundle's layout changed.
`excalidraw mermaid` runs `@excalidraw/mermaid-to-excalidraw` (with Pele) and `@excalidraw/element`'s `convertToExcalidrawElements` in the same browser page as the renderer, from `dist/mermaid.js` (see `scripts/build-mermaid.mjs`), which the browser loads only for Mermaid conversions. Both measure text with the canvas, so the page loads the labels' fonts and lays the diagram out again before converting it.

The build also writes `dist/reference.json`, every command's usage, arguments, options, examples and notes (see `src/reference.ts`). The [CLI docs](https://plus.excalidraw.com/docs/cli) are generated from the published package's copy and from the guides in `docs/`, which the package ships, so a release updates them: keep the guides' file names stable, and write each help line as one complete example or note. Keep the README short, and put the details in `docs/`.

To update the renderer, bump its pinned version in `devDependencies`, run `node scripts/update-fonts.mjs @excalidraw/excalidraw@<version>` with a release that ships the same fonts, and rebuild. The build fails if the bundle's layout changed. The README's CJK fonts section names that release too.

## Tests

Expand All @@ -27,7 +31,7 @@ pnpm run test:render
EXCALIDRAW_BROWSER_PATH=/path/to/chromium pnpm run test:render # if no browser is found
```

These render local fixtures and scenes from a mock API with an installed Chrome, Chromium or Edge, then check PNG dimensions and pixels. Run them once more with `EXCALIDRAW_BROWSER_PATH=/path/to/firefox` when you touch the renderer, since Firefox is the fallback. Font downloads go to a local mock mirror with a temporary cache, so the tests never use the network or your font cache.
These render local fixtures and scenes from a mock API with an installed Chrome, Chromium or Edge, then check PNG dimensions and pixels. Run them once more with `EXCALIDRAW_BROWSER_PATH=/path/to/firefox` when you touch the renderer, since Firefox is the fallback. A snap-packaged Firefox can't read the profile Playwright writes to `/tmp`; point `TMPDIR` at a folder the snap can reach, such as `~/snap/firefox/common/tmp`. Font downloads go to a local mock mirror with a temporary cache, so the tests never use the network or your font cache.

`pnpm run bench` (after a build) times complete commands and reports package and install sizes; add `--install` to measure a real install with dependencies.

Expand All @@ -45,6 +49,10 @@ The e2e suite runs real commands against a live workspace and deletes the resour

Every pull request runs the offline, rendering (with Chrome) and live API tests on Node 22. The live API tests use the test workspace key from the `EXCALIDRAW_E2E_API_KEY` secret, and `EXCALIDRAW_API_URL` from a repository variable if set. Pull requests from forks don't get the key, so their live API tests skip; a maintainer can push a fork's changes to a branch here to run them.

## Pull requests

Write the notes as [.github/PULL_REQUEST_GUIDE.md](.github/PULL_REQUEST_GUIDE.md) describes: short bullets about what changes for users, screenshots of anything visible, and test results.

## Releasing

Bump `version` in `package.json` on `master`, then push `master` to the `release` branch:
Expand Down
Loading