tailwind-conventions

Enforce Tailwind conventions with hard rules and scale-first class usage.

Updated Feb 17, 2026
One-click install
npx skills add https://github.com/aidanaden/sg-food-guide --skill tailwind-conventions-aidanaden
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tailwind-conventions
Source: https://github.com/aidanaden/sg-food-guide/tree/main/.agents/skills/tailwind-conventions
Command: npx skills add https://github.com/aidanaden/sg-food-guide --skill tailwind-conventions-aidanaden

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Tailwind CSS conventions help teams avoid styling inconsistencies by codifying project-specific rules and patterns for class usage, enabling faster development with cohesive visuals.

Core Features & Use Cases

  • Enforces hard rules for Tailwind usage (no arbitrary values in class names, no px in inline styles, and prioritizing scale classes).
  • Provides standardized replacements and guidance to streamline component styling and code consistency.
  • Use Case: When writing or reviewing UI components, apply these conventions to ensure uniform styling and predictable design across the app.

Quick Start

Apply the tailwind-conventions guide when styling or reviewing component code to ensure consistent Tailwind usage.

Frequently Asked Questions about tailwind-conventions

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I enforce consistent Tailwind class names across a component library?

Enforce Tailwind conventions by applying hard rules that prohibit arbitrary values and inline px styles, prioritizing scale-first class usage to ensure consistent component UX. This standardizes replacements and promotes predictable design system patterns across your codebase.

What are the best Tailwind CSS conventions for avoiding arbitrary values?

The best Tailwind CSS conventions prioritize scale classes over arbitrary values, enforcing hard rules against inline px styles. This approach streamlines component styling and ensures predictable visual cohesion across the application.

Can I use cva and the cn utility to manage Tailwind styling conventions?

Yes, you can integrate cva and the cn utility with Tailwind conventions to manage component styling patterns. This integration enforces hard rules and standardizes class names, ensuring uniform styling and predictable design across app components.

How do I review UI components for Tailwind styling inconsistencies?

Review UI components for Tailwind styling inconsistencies by checking for arbitrary values, inline px styles, and non-scale class usage. Apply standardized conventions to ensure uniform styling and predictable design across the app.

Why should I avoid arbitrary values in Tailwind class names?

Avoid arbitrary values in Tailwind class names to maintain design system cohesion. Enforcing scale-first usage and hard rules prevents styling inconsistencies, ensuring faster development with cohesive visuals across your component library.