design-md-format

Create, lint, diff, and export DESIGN.md design system token files.

4|Updated May 16, 2026
One-click install
npx skills add https://github.com/reason-machines/design-skills --skill design-md-format-reason-machines
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: design-md-format
Source: https://github.com/reason-machines/design-skills/tree/main/skills/design-md-format
Command: npx skills add https://github.com/reason-machines/design-skills --skill design-md-format-reason-machines

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @google/design.md.

What problem does it solve? Design systems are often documented informally, leaving AI coding agents without structured, machine-readable guidance on colors, typography, spacing, and components. This Skill provides the DESIGN.md format specification and CLI tooling to author, validate, compare, and export design tokens so agents and developers share a single source of truth. ## Core Features & Use Cases - Structured Token Authoring: Define colors, typography, rounded corners, spacing, and component tokens in YAML front matter paired with human-readable markdown rationale sections. - Linting and Validation: Run the CLI linter to catch broken token references, missing primary colors, orphaned tokens, section order issues, and WCAG AA contrast ratio failures. - Export and Diff: Convert tokens to Tailwind v3 JSON, Tailwind v4 CSS, or W3C DTCG format, and diff two DESIGN.md versions to detect token changes and regressions. - Use Case: A team codifies its brand guidelines into a DESIGN.md file, validates it in CI with the lint command, and exports tokens directly into their Tailwind configuration so generated UI code always matches the design system. ## Quick Start Ask the agent to create a DESIGN.md file for your design system with primary colors, typography, and button component tokens, then lint it for WCAG contrast issues.

Frequently Asked Questions about design-md-format

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a DESIGN.md file for my design system?▼

Write YAML front matter with a required name field plus colors, typography, rounded, spacing, and components tokens, followed by markdown sections like Overview, Colors, and Typography. Validate the result with npx @google/design.md lint DESIGN.md.

How do I export design tokens to Tailwind config?▼

Run npx @google/design.md export --format json-tailwind DESIGN.md for a Tailwind v3 JSON theme, or --format css-tailwind for a Tailwind v4 CSS @theme block. A DTCG format is also available for W3C-compliant token output.

Does the DESIGN.md linter check WCAG contrast ratios?▼

Yes, the linter evaluates component backgroundColor and textColor pairs against the WCAG AA 4.5:1 contrast minimum and reports violations as warnings. It also flags broken token references and missing primary colors.

Why does npm install @google/design.md fail with ENOVERSIONS?▼

This error occurs when npm is not querying the public registry, often due to a custom registry in .npmrc or a corporate mirror. Check npm config get registry, ensure it points to https://registry.npmjs.org/, clear the cache, and retry.

How do I compare two versions of a design system file?▼

Use npx @google/design.md diff old.md new.md to see token-level changes grouped by added, removed, and modified entries per section. The command exits with code 1 when the newer version introduces regressions such as more lint errors.

Why does the design.md CLI not run in package.json scripts on Windows?▼

On Windows, the design.md command name conflicts with file association handling in npm scripts. Use the designmd alias instead, for example "design:lint": "designmd lint DESIGN.md" in your package.json scripts.