Token linting in zeroheight’s MCP gives you an automated way to keep your design tokens in sync between design and code. You can lint code written by humans or coding agents can lint the code they write as they write it.
Check out this demo:
Learn more about enabling the remote MCP and using the remote MCP.
Connecting zeroheight Token Sets to the MCP
To connect your token sets to the MCP, first create a token set in zeroheight from you tokens source of truth.
Then you can associate your token set with the remote MCP via Styleguide Settings > MCP and Markdown.
Lint your code
Now you can ask your coding agent to "lint code using zeroheight":
- The agent will discover the token sets available
- where more than 1 is available, it will ask the user to confirm which set should be used
- Then the agent will pass the contents of the open file to the zeroheight MCP with the details of the token set to be used
- The zeroheight MCP will then compare the styles in the code to the values in the token set and return a summary of violations back to the agent
- the linting tool will identify instances where hard coded styles exactly and/or closely match tokens in zeroheight
- The agent can then summarise these findings and/or apply the suggested fixes