Learn-skills.dev modern-tailwind
Build clean, scalable UIs with Tailwind CSS using modern utilities and variants
install
source · Clone the upstream repo
git clone https://github.com/NeverSight/learn-skills.dev
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/NeverSight/learn-skills.dev "$T" && mkdir -p ~/.claude/skills && cp -r "$T/data/skills-md/academind/ai-config/modern-tailwind" ~/.claude/skills/neversight-learn-skills-dev-modern-tailwind && rm -rf "$T"
manifest:
data/skills-md/academind/ai-config/modern-tailwind/SKILL.mdsource content
Tailwind CSS Best Practices
Core Principles
- Prefer utility classes over custom CSS for most styling
- Keep class lists readable by grouping: layout → spacing → typography → color → effects
- Use semantic HTML first; utilities should enhance, not replace structure
Variants & State
- Use
,hover
,focus-visible
,disabled
, anddark
variants where appropriatemotion-safe - Prefer
anddata-*
variants for stateful styling tied to DOM semanticsaria-* - Use
andgroup
for parent/sibling state without extra JSpeer
Responsive & Container Queries
- Start with the base styles, then add responsive variants (
,sm
,md
, ...)lg - Use container query utilities when layout depends on parent size
Theming & Customization
- Extend the theme in
instead of ad-hoc custom classestailwind.config - Use
for custom utilities/components when repetition is unavoidable@layer - Avoid
except for small, repeatable patterns@apply
Maintainability
- Extract reusable UI into components instead of repeating large class strings
- Keep class names deterministic; avoid dynamic string concatenation when possible