Skip to main content
Glama
vitkuz573

tailwind-mcp

by vitkuz573

Validate Tailwind classes

tailwind_validate
Read-only

Validate candidate Tailwind classes against your project and return the CSS they generate. Use before writing markup to avoid emitting classes that do not exist.

Instructions

Check whether candidate Tailwind classes exist in this project and return the CSS they generate. Accepts variants (md:hover:bg-red-500) and arbitrary values (w-[37px]). Use before writing markup to avoid emitting classes that do not exist.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
projectNoAbsolute path to the project to inspect. Defaults to the server's working directory. Use it when the Tailwind project is not the current working directory.
candidatesYesTailwind class candidates to validate, e.g. ['p-4', 'bg-red-500', 'text-nope']

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already establish readOnlyHint=true and openWorldHint=false, so the safety profile is covered. The description adds real value beyond that: it discloses accepted input forms (variants like md:hover:bg-red-500, arbitrary values like w-[37px]) and that CSS is produced as a result. It omits how unknown classes are reported, which keeps it below a 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three tight sentences: purpose and return first, then accepted input forms, then the usage trigger. Every sentence earns its place with no repetition or filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description does carry the burden of explaining the return, and it does say CSS is generated. However, it does not describe the response shape (e.g. per-candidate validity flags or how failures appear), so it is nearly but not fully complete for a two-param read-only tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so both parameters are already documented, including the project default. The description's variant/arbitrary-value examples add mild meaning but largely echo what the schema already conveys, making the baseline 3 appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (check/validate) and resource (Tailwind class candidates) with explicit scope ('in this project') and the return ('the CSS they generate'). It is distinguishable from most siblings, but it does not explicitly contrast itself with close neighbors like tailwind_conflicts or tailwind_canonicalize.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

'Use before writing markup to avoid emitting classes that do not exist' gives a clear use context and a proactive trigger. It does not name alternative siblings or state when not to use it, so it stops short of full routing guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.