tailwind-css-patterns

Implements responsive Tailwind CSS utility patterns for React, Vue, and Svelte components.

1|Updated May 23, 2026
One-click install
npx skills add https://github.com/palfish-t-i-u/palfish-t-i-u-h-th-ng-ver-2 --skill tailwind-css-patterns-palfish-t-i-u
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tailwind-css-patterns
Source: https://github.com/palfish-t-i-u/palfish-t-i-u-h-th-ng-ver-2/tree/main/.claude/skills/tailwind-css-patterns
Command: npx skills add https://github.com/palfish-t-i-u/palfish-t-i-u-h-th-ng-ver-2 --skill tailwind-css-patterns-palfish-t-i-u

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Styling modern web interfaces consistently across breakpoints, dark mode, and accessibility requirements requires deep knowledge of Tailwind CSS utilities, and misconfigured content paths or class ordering often cause silent styling failures in production. ## Core Features & Use Cases - Responsive Layout Patterns: Mobile-first flexbox, grid, spacing, and typography utilities with breakpoint prefixes from sm to 2xl, plus container queries for component-level responsiveness. - Component & Dark Mode Patterns: Ready-to-use card, navigation, form, and modal markup with dark mode variants and React toggle implementations. - Configuration & Performance Guidance: CSS-first @theme configuration for Tailwind v4.1+, custom utilities and variants, content path setup, and production purging best practices. - Use Case: When building a responsive product card grid in a React app, apply the documented grid and card patterns, add dark mode variants, and verify focus rings and reduced-motion support before shipping. ## Quick Start Ask the assistant to style a React component with Tailwind CSS, for example to build a responsive card grid with dark mode support and accessible focus states.

Frequently Asked Questions about tailwind-css-patterns

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

FAQPage Schema
How do I build a responsive grid layout with Tailwind CSS?

Use grid utilities with responsive prefixes, such as grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-4, to stack items on mobile and expand columns on larger screens. Tailwind is mobile-first, so base classes apply to small screens and prefixes override them at larger breakpoints.

How to add dark mode to a Tailwind CSS project?

Configure darkMode as 'class' or 'media' in your config, then apply dark: variants like bg-white dark:bg-gray-900. For class strategy, toggle the dark class on the html element with document.documentElement.classList.toggle('dark').

Why are my Tailwind classes not applying in production?

Classes are usually purged because content paths in the config do not include all template files. Verify the content array covers your source files, rebuild the CSS, and avoid constructing class names dynamically at runtime since the scanner only detects literal strings.

Does Tailwind CSS v4 support container queries?

Yes, Tailwind v4.1 supports container queries using the @container class on a parent and variants like @lg: or @[400px]: on children. This lets components respond to their container width rather than the viewport size.

When should I use @apply versus utility classes in Tailwind?

Prefer composing utility classes directly in markup for maintainability, and reserve @apply for extracting repeated patterns into component classes within @layer components. Overusing @apply with complex selectors can cause specificity issues and larger stylesheets.