design-to-code

design-to-code is a skill for Claude Code, Codex from fitoe/DesignToCode. It costs 55 tokens per session (2,326 once invoked), scanned A, original, MIT.

A workflow for turning approved designs, mockups, or visual specifications into application code and checking the result with screenshots.

In plain words
What is it for?
Use it to map designs to components, implement pages, repair visual mismatches, and record evidence of visual parity.
Why use it?
It helps keep implementation aligned with the approved layout and makes visual differences easier to identify and repair.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/fitoe/designtocode/design-to-code
Any agent
npx skills add fitoe/DesignToCode --skill design-to-code
Clone the repo
git clone --depth 1 https://github.com/fitoe/DesignToCode

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for design-to-code

README.md
[![agentmods](https://agentmods.dev/badge/skills/fitoe/designtocode/design-to-code.svg)](https://agentmods.dev/skills/fitoe/designtocode/design-to-code)
Your own site
<a href="https://agentmods.dev/skills/fitoe/designtocode/design-to-code"><img src="https://agentmods.dev/badge/skills/fitoe/designtocode/design-to-code.svg" alt="Measured on agentmods" height="20"></a>
Per session 55 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,326 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00055 $0.02326
Opus 5 $0.00028 $0.01163
Sonnet 5 $0.00011 $0.00465
Haiku 4.5 $0.00006 $0.00233

Measured 3d ago against content hash 887237ba64db, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

design-to-code scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/design-to-code/SKILL.md · 174 lines

How it starts

The opening of the file, as written. The whole thing — 174 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Design to Code

Purpose

Turn an approved visual source into maintainable code without relying on prose precision. Prefer structured inputs, small implementation passes, and screenshot-backed parity evidence.

Ownership Boundary

design-to-code owns work after design approval/handoff:

  • implementation mapping and code changes
  • extracting implementation details from approved visual sources
  • data-section anchors and section-level parity evidence
  • visual repair, mismatch/debt notes, accepted deviations

Return to idea-to-design only when the approved source is missing/stale, scope changed, the handoff predates approval, or the user asks for a design change.

Input Priority

  1. implementation-blueprint.json + page-matrix.json + component-blueprint.json + debt-ledger.json
  2. Visual IR / section contract (visual-ir/<page-id>.json, visual-contracts/*, section crops)
  3. Approved design images / Figma context / persisted mockups
  4. Page briefs and prose notes

Prose briefs are supporting context, not the source of truth.

Fidelity Path

D2C has one default path: highest-fidelity-regeneration.

Use D2C only when converting or repairing against an approved visual source and the expected result is the highest practical design-source fidelity. Do not downgrade to quick, standard, or "structure-first" modes unless the user explicitly waives fidelity for that specific task.

For every visual D2C page/section:

  • approved visual source is the source of truth; prose only supports it
  • load the highest-fidelity references before coding, not after a mismatch appears
  • extract executable section-level IR before implementation
  • inventory visible text, icons, shapes, tokens, assets, and controls before coding; for mobile pages include icon anatomy, icon size tokens, and Iconify visual compensation
  • implement from the inventory/IR, then generate left-design/right-live evidence
  • any shortcut, placeholder, missing icon, or simplified asset is debt and must be named before showing the result

Read the full file on GitHub · 174 lines

Files

What ships with it

40 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 174 lines · 55 tokens per session scan A 887237ba64db

Subscribe to this mod's changes

design-to-code is a skill published in the GitHub repository fitoe/DesignToCode (6 stars, last pushed 3mo ago), licensed MIT. It adds 55 tokens to every session and 2,326 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

figma-typings-audit

Upgrade @figma/plugin-typings and absorb what the new version exposes. Diffs the .d.ts between the installed and the target version (that package ships no changelog), sorts the changes into breakage / new API / silently-added fields, maps each onto the sandbox handlers, the hand-written Zod mirrors in shared, and the…

awdr74100/figwright · 133 tokens

figma-codegen

Generate framework-aware code from a Figma design. Reads the project's stack profile and emits code matching the existing framework (React/Vue/Svelte/Next/etc.) and styling (Tailwind/CSS/CSS-in-JS), reusing existing components and design tokens instead of regenerating from scratch. Triggers whenever the user wants a…

awdr74100/figwright · 145 tokens

figma-build

Build a Figma design from code or a description — the reverse of figma-codegen. Reuses the connected file's existing design system (components, variables, styles) instead of drawing primitives with hardcoded values. Triggers whenever the user wants something created or updated IN Figma from code or a spec — e.g.…

awdr74100/figwright · 180 tokens

markdy-diagram-author

Author, design, and optimize kinetic architecture diagrams using MarkdyScript DSL. Use when creating system designs, cloud topologies, sequence diagrams, microservices flows, or converting static diagrams to animated 60fps scenes.

HoangYell/markdy-com · 49 tokens

penpot-mcp

Use this skill whenever the user wants to use AI agents to work with Penpot design files via the Penpot MCP Server. Triggers include: using Penpot through an AI agent, design files, design systems, design tokens, Penpot MCP, design-to-code, generating UI from design, auditing a design system, creating…

ar27111994/penpot-mcp · 175 tokens

stitch-ideate

Conversational design ideation agent that researches trends, explores visual directions, and refines ideas through adaptive questioning — then produces a rich PRD document and auto-generates Stitch screens. Your design buddy that thinks deeply before designing.

gabelul/stitch-kit · 51 tokens