# Your codebase already has a design system

> Source: <https://dev.to/technicalyblond/your-codebase-already-has-a-design-system-1dg6>
> Published: 2026-11-26 09:37:00+00:00

**Key takeaway:** Saer's MCP server lets a coding agent read the codebase's existing tokens and components with per-finding evidence before writing, and never upgrades an unknown or experimental finding into a fact.

A frontend codebase has a design system long before anyone writes one down. It is in the colours people reach for, the values that keep coming back, the tokens that get used and the ones that quietly stop being used. When a team does declare a system, the code keeps moving: a raw value lands next to the token it should have used, a near copy of a colour arrives, a role that clearly exists never gets a name.

Coding agents make this faster. An agent asked for a button may find the declared token and three raw values that look almost the same, with nothing to say which one is the system. Adding a fourth is the easy path.

Most projects have two design systems: the one that is declared, in config and custom properties, and the one that is in use. The useful question is not whether the code follows the declared system. It is what the system actually is, and where the two disagree.

Saer is a CLI I built to answer that. It scans an existing frontend codebase and infers the design system that actually exists. The private beta reads colour, type, spacing and the other foundations, and the components themselves: it takes the Tailwind config, CSS custom properties, the React components and how they are used, and reconciles them into one model of the system.

The findings are split by how sure Saer can be:

I also tested whether the same model carries over beyond colour. It did. Type, spacing, radius, shadows and the other foundations use the same states and the same split between exact and inferred findings, and components get their own: variants passed but never declared, and call sites that restyle what a component already sets. Each area went into the beta only once its drift detection was as deep as colour's, because a report that is shallow in one place is harder to trust everywhere.

The worst output a tool like this can produce is not a missing finding. It is a confident wrong one, or a clean report built on no evidence.

Both happened during development. A CSS file that nested its dark and light themes inside one root block was read as flat, and a light value was reported as dark, as a known fact, with no warning. The fix was a structural CSS parser instead of searching the text for closing braces. Separately, a repo where Saer found no colour system at all was reported as fully resolved. The fix there was to judge evidence at the level of the whole report, as sufficient, partial or insufficient, so a report with nothing behind it cannot look clean.

Saer now separates two kinds of "I can't tell you". Unknown means the repo does not contain enough evidence to answer. Unresolved means Saer met something it cannot read yet. The second is a limit of the tool, so it is never turned into a question for the person reading the report.

Scanning is local and deterministic. No AI model runs at scan time, the free scan needs no account, and the only thing a scan writes is one output folder inside the scanned project. For the same repository and the same version, the report is identical apart from its timestamp, on every supported machine. A design system tool that gives a different answer on a different machine is not describing the system.

The second half is a local MCP server over the scan. Before a task, a coding agent can ask which existing components, variants and tokens to build it from, with the evidence for each. After it writes, it can check only the lines it changed, against the same rules as the scan. The server reads the scan and the files, sends none of your code anywhere, and the only thing it can write is a fresh scan in that same output folder.

The rule that matters most is that the server can never upgrade a state. Unknown stays unknown, and an experimental finding never arrives as a fact. Before it writes a new value or a new component, a coding agent can read the tokens and components the codebase already has, the evidence for each, and what is still in doubt. That is the difference between an agent guessing at a system and an agent building with the real one.

Saer is in private beta. You can try the free colour scan or request early access at saer.app.
