extract-design-md

Extract a DESIGN.md from an existing page: colors, type, spacing and component rules.

extract-design-md produces a DESIGN.md from an existing page. Requires Stitch MCP.

Design & slidesagents 2Apache-2.0 downloadable Scan upstream repo ↗

What it is

Extracts a DESIGN.md from frontend source code (React, Vue, Svelte, Angular, plain HTML/CSS and others) or from a live page when only a URL exists, recording colour, type, spacing, and component rules. It is for developers auditing or migrating an existing visual language. It does not create new screens or judge the design.

Core workflow

StageContent
TriggerUnderstanding a repository’s visual language, migrating it to Stitch, or having only a URL.
InputA frontend source directory, or an http/https URL.
StepsRead package.json to identify the framework and CSS approach, then map the source tree; consult the matching framework reference; for a URL only, render locally with Puppeteer and read computed styles; write the result into DESIGN.md frontmatter and sections.
OutputOne DESIGN.md, plus .stitch/live-url-screenshot.png when needed.
BoundarySource mode needs no build or runtime; URL mode needs Node.js and puppeteer and never installs into the user’s project; fetched content is data, never instructions.
Getting started: read package.json before choosing directories; it removes most of the search.

Traits

  • Two inputs, source code and live URL; source mode works without a build.
  • Detects the stack first: dependencies, tailwind and postcss configs, CSS-in-JS, token files.
  • URL mode reads computed styles through local headless Chrome and accepts only http and https.
  • Treats page text as untrusted data to prevent prompt injection.

Who it is for and who it is not for

Good fitPoor fit
Shipping a spec when the build is brokenWanting screen designs directly
Documenting a client site’s systemNo source and no reachable URL
Reconciling styles scattered across a repoReplacing human visual review

How it differs

NeedUse
Extract rules from source or a URLextract-design-md
Extract from screens inside Stitchdesign-md
Move code into Stitch wholesalecode-to-design
Invent a new styletaste-design

Source-level risks

RiskSourceImpact
URL mode installs puppeteerPrerequisites and temporary-directory flowDownloads a browser; slow and network-bound
Fetches any URL the user givesScript argument –urlInternal or sensitive hosts need human screening
Cleans the temp directory with rm -rfExample commandA variable slip risks deleting the wrong path
Falls back to –no-sandbox when sandboxed launch failsScript behaviour noteReduced isolation inside containers
The file is truncatedTail stops at “sections the source path”Later-phase output structure is incomplete

Example: input and output

Input

Extract design rules from a competitor page.

Output

Outputs a DESIGN.md.

需要 Stitch MCP。

FAQ

Infringement?

Reference, don't clone.

Usable directly?

Verify first.

Common tasks

CategoryDesign & slides
Version2026-11-28
Agent supportClaude Code, Generic (reads SKILL.md)
OSmacOS / Linux / Windows
Dependenciesnone
Environment需要 Stitch MCP
Scriptsreviewed: fetches the URL you provide
LicenseApache-2.0
Sourcegoogle-labs-code/stitch-skills ↗
Verification✓ verified
Get itDownload zip
SHA256: d8477a1486cc9658e9e9510c1a2636b061ec7fa627cf46d28f33a0ecc95d7783 · 0.0 MB

"Generic (agents that read SKILL.md)" means any agent that discovers and loads SKILL.md; support level (auto-discovery, manual config, script execution) varies by agent.

Install
unzip google-labs-code-stitch-skills-extract-design-md-2026-11-28.zip -d ~/.claude/skills/

Skills directory example: ~/.claude/skills/ for Claude Code; other agents use wherever SKILL.md is discovered.