Why do Claude Code and Cursor ignore my design system?

Short answer

Claude Code and Cursor work from what is in their context: the task, the files they open and any rules you give them. If your Button lives three folders away, or your tokens are only defined through a Tailwind config and var() chains, the agent never sees them and writes markup and raw values from scratch. Three things fix most of it: a short, current section in CLAUDE.md, AGENTS.md or your Cursor rules naming the components and the rule (no raw value where a token exists), a way for the agent to look components and tokens up on demand, and a check on every change it makes.

Tell the agent in the files it already reads

Keep it short and specific. A long style guide gets skimmed; a list of the components to reach for and one hard rule gets followed.

## UI
- Use the components in src/components/ui (Button, Input, Card, Dialog, Toast) before writing new markup.
- Never write a raw colour, font size or spacing value when a token exists. Tokens: src/styles/tokens.css.
- After a UI change, call the saer_check tool on the files you touched and fix what it reports.

Let it look things up

A rules file goes stale the day a component is added. Agents do better when they can ask: which component fits this UI, what props it takes, which token a value should be. saer mcp answers those questions from a scan of the code, for Claude Code, Cursor and Codex. See agents.

Check what it wrote

Instructions reduce mistakes; a check catches the rest. A raw value identical to a token is always fixable, and hand-built UI where the component exists is worth a look before it merges. Saer runs that check in the agent's loop (the saer_check tool) and on the pull request (saer ci). See CI checks.

saer init

What Saer does about this

Today
  • saer init (in the beta) adds a short Saer section to AGENTS.md or CLAUDE.md and connects Claude Code, Cursor or Codex, asking before each change.
  • saer mcp (in the beta) answers component, token and check questions for Claude Code, Cursor and Codex from a scan of your code.
Not yet
  • A published benchmark of agent output with and without Saer: internal rounds have run with Codex only; results are published with their full method once reviewed.

Every capability and its state: what Saer checks.

See it on your own codebase.

Start free trial