● v0.1 · MIT · Open source
No save button, no design mode, no proprietary file. Because everything is React, every LLM already knows how to edit it — no plugin, no MCP, no SDK. Pan-and-zoom artboards, sub-second hot reload, headless PNG/JPG export.
npx create-lerret@latest my-canvas
Why it works
Everything else — git-native versioning, AI-fluent editing, no vendor lock-in — falls out for free.
01 — The folder is the project
No save button, no design mode, no proprietary file. The .lerret/ directory on disk is the project — Lerret only reflects what's already there. Git treats it like any other folder. If Lerret disappears tomorrow, you still have a working set of React components.
02 — The format is React
Because everything is React, every LLM already knows how to edit it — no plugin, no MCP, no design-tool SDK. Just files an AI was trained on millions of times over. AI-native by substrate, not by feature roadmap.
One file
Each .jsx file under .lerret/ becomes an artboard. The default export is the component; named exports become variants. The meta export tells Lerret the dimensions, tags, and (optionally) a propsSchema for the in-studio data editor.
That's it. Save the file and the canvas re-renders.
// .lerret/social/twitter-banner.jsx
export default function TwitterBanner() {
return (
<div style={{
width: 1500,
height: 500,
padding: '4rem',
background: 'linear-gradient(135deg, #B85B33, #E0833F)',
color: 'white',
fontFamily: 'system-ui',
}}>
<h1 style={{ fontSize: 72, fontWeight: 800, margin: 0 }}>
Hello from Lerret
</h1>
<p style={{ fontSize: 24, opacity: 0.85, marginTop: '1rem' }}>
It's just a React component.
</p>
</div>
);
}
export const meta = {
dimensions: { width: 1500, height: 500 },
tags: ['twitter', 'banner'],
}; ✶ Built-in AI
An AI agent lives in the studio dock. Prompt it — “re-theme the banner to our brand”, “make a launch kit from this component” — and it reads, writes and restructures the files in your .lerret/ folder. Tell it your brand once; every asset it makes is anchored to your colors, type and voice.
.lerret/ only, with a step cap and one-click revert on every turn.
Prefer your own tool? Every project also ships Claude Code, Cursor, Copilot & AGENTS.md conventions — edit with /lerret-edit or any agent.
What's in the box
Your project folder becomes a navigable visual canvas. Pages and groups map directly to folders. Focus mode for one artboard at a time.
Save a .jsx file and the artboard re-renders in under a second. Vite React Fast Refresh, native — no transpile step, no proxy.
Single artboard, page group, or the whole project to PNG/JPG — fonts fully embedded, foldered to mirror your pages. Headless Chromium, runs in CI.
export const Dark = … gives the same component a second variant on the same canvas. No new file, no new convention.
Declare a propsSchema in meta and Lerret generates a typed form — edit props in the studio, written back to a .data.json, no code touched.
A per-folder config.json cascades colors, CSS vars and shared data down the tree. Drop .woff2 in _fonts/ for global fonts; .md files render as cards.
Three deploy modes
One React codebase. Three ways to deliver the same canvas against the same folder. Switch freely — your .lerret/ directory has zero Lerret code in it.
CLI
npx @lerret/cli@latest dev against any folder. Native Vite HMR. Your daily dev loop.
Hosted
The studio as a static site; open any local folder via the File System Access API. Chromium browsers only.
Self-host
The same static studio, packaged for self-deployment. Private and team contexts. Same renderer.
A small workspace of focused packages
@lerret/cli User-facing CLI — dev + export. Bundles the studio. @lerret/core Environment-agnostic engine — loader, watcher, config cascade. create-lerret Project scaffolder — npx create-lerret@latest my-canvas. What it isn't
Lerret is small on purpose. Three things it's not:
Figma is a vector design tool with a proprietary file format and a collaborative cursor culture. Lerret is a rendering canvas for code. Different category.
Every asset is a React component. If you don't write React, Lerret won't be your day-one tool.
There's no backend. Hosted mode is just a static site that talks to your local filesystem via the browser.
Get started
npx create-lerret@latest my-canvas
cd my-canvas
npx @lerret/cli@latest dev
The studio opens in your browser. Save any .jsx file under .lerret/ and the canvas re-renders. Requires Node ≥ 20.19.