tailwind-css
Skill2 starsChanged 27 days agoMITView on GitHub
This skill should be used when the user asks to style with Tailwind v4, add or fix Tailwind classes, use tailwind-variants or tw-animate-css, or configure Tailwind. Trigger phrases include "style with Tailwind", "fix Tailwind styles", "configure Tailwind v4", "migrate to Tailwind v4".
9 other projects use a version of this, 1 of them edited.
Adopted by
Most recently taken up by
- mahdy-gribkov/arcanatheir own version, first seen Nov 8, 2026
- PaulRBerg/dot-agentstheir own version, first seen Nov 6, 2026
- medy-gribkov/arcanatheir own version, first seen Nov 1, 2026
- PaulRBerg/agent-skillstheir own version, first seen Oct 24, 2026
- blakee-marcus/tailwindcss-skilltheir own version, first seen Oct 20, 2026
- nek1987/auto-agent-harnesstheir own version, first seen Oct 11, 2026
Other versions9 projects use a version of this.
Word for word · 0
None found.
Edited · 1
- sablier-labs/agent-skills★ 912% same
Wrote their own version · 8
- cohen-liel/hivemind★ 108same name
- PaulRBerg/agent-skills★ 104same name
- PaulRBerg/dot-agents★ 6same name
- nek1987/auto-agent-harness★ 4same name
- afk-agents/agentic-toolkit★ 1same name
- mahdy-gribkov/arcana★ 1same name
- medy-gribkov/arcana★ 1same name
- blakee-marcus/tailwindcss-skill★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository192 other files it gives its agents.
- clickhouse-architecture-advisor/AGENTS.mdAGENTS.md
- clickhouse-best-practices/AGENTS.mdAGENTS.md
- unsafe-checker/AGENTS.mdAGENTS.md
- alertmanager-querySkill
- analyzing-range-distributionSkill
- analyzing-schema-change-storage-riskSkill
- argocdSkill
- aspire-configurationSkill
- aspire-integration-testingSkill
- aspire-service-defaultsSkill
- auditing-cloud-cluster-securitySkill
- auditing-table-statisticsSkill
- benchmarking-transaction-patternsSkill
- cepthSkill
- chdb-datastoreSkill
- chdb-sqlSkill
- clickhouse-architecture-advisorSkill
- clickhouse-best-practicesSkill
- clickhousectl-cloud-deploySkill
- clickhousectl-local-devSkill
- cockroachdb-sqlSkill
- coding-guidelinesSkill
- configuring-audit-loggingSkill
- configuring-ip-allowlistsSkill
- configuring-log-exportSkill
- configuring-private-connectivitySkill
- configuring-sso-and-scimSkill
- create-technical-architecture-documentSkill
- csharp-mstestSkill
- csharp-tunitSkill
- csharp-xunitSkill
- designing-application-transactionsSkill
- designing-multi-region-applicationsSkill
- domain-cliSkill
- domain-cloud-nativeSkill
- domain-embeddedSkill
- domain-fintechSkill
- domain-iotSkill
- domain-mlSkill
- domain-webSkill
- dotnet-aot-wasmSkill
- dotnet-aspire-patternsSkill
- dotnet-benchmarkdotnetSkill
- dotnet-blazor-authSkill
- dotnet-blazor-componentsSkill
- dotnet-blazor-patternsSkill
- dotnet-blazor-testingSkill
- dotnet-channelsSkill
- dotnet-ci-benchmarkingSkill
- dotnet-cli-architectureSkill
- dotnet-cli-distributionSkill
- dotnet-cli-packagingSkill
- dotnet-cli-release-pipelineSkill
- dotnet-containersSkill
- dotnet-cryptographySkill
- dotnet-csharp-dependency-injectionSkill
- dotnet-csharp-modern-patternsSkill
- dotnet-csharp-nullable-reference-typesSkill
- dotnet-csharp-source-generatorsSkill
- dotnet-maui-doctorSkill
- The first 60 shown.
The file
Show its rules and text
We split this skill into the rules it gives an agent
16 rules. 0 are common, 4 are distinctive, and 12 are very specific to this project.
0
Common
Most of the 9 edited versions we read keep these.
4
Distinctive
This author's own choices. Worth a look.
12
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 35
All theme tokens defined with @theme automatically become available as utility classes.
- Very specific: line 39
Use eslint-plugin-better-tailwindcss for Tailwind CSS v4 class validation and style enforcement.
- Distinctive: line 72
Run the project's ESLint check after modifying Tailwind classes to validate all changes across the codebase.
- Distinctive: line 80
Use CSS Modules only as a last resort for complex CSS that cannot be easily written with Tailwind classes.
- Very specific: line 100
Read references/tailwind-variants.md for patterns
- Very specific: line 101
Check the project's @theme configuration for available tokens
- Very specific: line 102
Use tv() from tailwind-variants for type-safe variants
- Very specific: line 127
Check references/tailwind-v4-rules.md for breaking changes
- Very specific: line 128
Verify gradient syntax (bg-linear-*, not bg-gradient-*)
- Very specific: line 129
Verify CSS variable syntax (bg-my-color, not bg-[--var-my-color])
- Very specific: line 130
Check if arbitrary value exists in the project's @theme configuration
- Very specific: line 134
Check the project's @theme configuration first to see available colors
- Distinctive: line 135
Use semantic color names when available
- Very specific: line 136
Use opacity modifiers for transparency (/20, /50, etc.)
- Distinctive: line 137
Avoid arbitrary colors unless absolutely necessary
- Very specific: line 151
Read references/tw-animate-css.md for available animations
“Common” is measured: kept by at least 6 in 10 of the 9 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Tailwind CSS v4
Expert guidance for Tailwind CSS v4, CSS-first configuration, modern utility patterns, and type-safe component styling with tailwind-variants.
CSS-First Configuration
Tailwind CSS v4 eliminates tailwind.config.ts in favor of CSS-only configuration. All configuration lives in CSS files using special directives.
Core Directives:
@import "tailwindcss"- Entry point that loads Tailwind@theme { }- Define or extend design tokens@theme static { }- Define tokens that should not generate utilities@utility- Create custom utilities@custom-variant- Define custom variants
Minimal Example:
@import "tailwindcss";
@theme {
--color-brand: oklch(0.72 0.11 178);
--font-display: "Inter", sans-serif;
--spacing-edge: 1.5rem;
}All theme tokens defined with @theme automatically become available as utility classes. For example, --color-brand can be used as bg-brand, text-brand, border-brand, etc.
ESLint Integration
Use eslint-plugin-better-tailwindcss for Tailwind CSS v4 class validation and style enforcement.
Correctness Rules (errors):
no-conflicting-classes- Detect classes that override each otherno-unknown-classes- Flag classes not registered with Tailwind
Stylistic Rules (warnings):
enforce-canonical-classes- Use standard v4 class namesenforce-shorthand-classes- Use abbreviated class versionsno-deprecated-classes- Remove outdated class namesno-duplicate-classes- Eliminate redundant declarationsno-unnecessary-whitespace- Clean up extra spacing
Examples:
// ❌ Bad: separate padding
<div className="px-6 py-6">
// ✅ Good: shorthand
<div className="p-6">// ❌ Bad: separate width/height
<div className="w-6 h-6">
// ✅ Good: size utility
<div className="size-6">Run the project's ESLint check after modifying Tailwind classes to validate all changes across the codebase.
Coding Preferences
For detailed coding patterns covering layout, spacing, typography, colors, borders, gradients, arbitrary values, class merging, image sizing, z-index, and dark mode, see references/coding-preferences.md.
CSS Modules
Use CSS Modules only as a last resort for complex CSS that cannot be easily written with Tailwind classes.
All .module.css files must include @reference "#tailwind"; at the top to enable Tailwind utilities and theme tokens inside the module.
Example:
/* component.module.css */
@reference "#tailwind";
.component {
/* Complex CSS that can't be expressed with Tailwind utilities */
/* Can still use Tailwind utilities and theme tokens */
}Common Tasks
Adding a Component with Variants
- Read
references/tailwind-variants.mdfor patterns - Check the project's
@themeconfiguration for available tokens - Use
tv()fromtailwind-variantsfor type-safe variants
Example:
import { tv } from "tailwind-variants";
const button = tv({
base: "rounded-lg px-4 py-2 font-medium",
variants: {
color: {
primary: "bg-blue-600 text-white",
secondary: "bg-gray-600 text-white",
},
size: {
sm: "text-sm",
md: "text-base",
lg: "text-lg",
},
},
});Debugging Styles
- Check
references/tailwind-v4-rules.mdfor breaking changes - Verify gradient syntax (
bg-linear-*, notbg-gradient-*) - Verify CSS variable syntax (
bg-my-color, notbg-[--var-my-color]) - Check if arbitrary value exists in the project's
@themeconfiguration
Working with Colors
- Check the project's
@themeconfiguration first to see available colors - Use semantic color names when available
- Use opacity modifiers for transparency (
/20,/50, etc.) - Avoid arbitrary colors unless absolutely necessary
Example:
// ✅ Good: theme token with opacity
<div className="bg-brand/20 text-brand">
// ❌ Avoid: arbitrary hex
<div className="bg-[#4f46e5]/20 text-[#4f46e5]">Adding Animations
- Read
references/tw-animate-css.mdfor available animations - Combine a base class (
animate-inoranimate-out) with effect classes - Note decimal spacing gotcha: use
[0.625rem]syntax, not2.5
Example:
// Enter: fade + slide up
<div className="fade-in slide-in-from-bottom-4 duration-300 animate-in">
// Exit: fade + slide down
<div className="fade-out slide-out-to-bottom-4 duration-200 animate-out">Quick Reference Table
| Aspect | Pattern |
| Configuration | CSS-only: @theme, @utility, @custom-variant |
| Gradients | bg-linear-*, bg-radial, bg-conic |
| Opacity | Modifier syntax: bg-black/50 |
| Line Height | Modifier syntax: text-base/7 |
| Font Features | font-features-zero, font-features-ss01, etc. |
| CSS Variables | bg-my-color (auto-created from @theme) |
| CSS Modules | @reference "#tailwind"; at top |
| Class Merging | cn() for conditionals; plain string for static |
| Viewport | min-h-dvh (not min-h-screen) |
| Component Variants | references/tailwind-variants.md |
| Animations | references/tw-animate-css.md |
| V4 Rules | references/tailwind-v4-rules.md |
Reference Documentation
- Tailwind v4 Rules & Best Practices:
references/tailwind-v4-rules.md— Breaking changes, removed/renamed utilities, layout rules, typography, gradients, CSS variables, new v4 features, common pitfalls - tailwind-variants Patterns:
references/tailwind-variants.md— Component variants, slots API, composition, TypeScript integration, responsive variants - tw-animate-css Reference:
references/tw-animate-css.md— Enter/exit animations, slide/fade/zoom utilities, spacing gotchas
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

