tailwind-v4-shadcn

Configure Tailwind CSS v4 and shadcn/ui for React and Vite projects.

3|2|Updated Mar 25, 2026
One-click install
npx skills add https://github.com/zaid-khan-code/learnHub-ai-powered-online-learning-platform-lms --skill tailwind-v4-shadcn-zaid-khan-code
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: tailwind-v4-shadcn
Source: https://github.com/zaid-khan-code/learnHub-ai-powered-online-learning-platform-lms/tree/main/.agents/skills/tailwind-v4-shadcn
Command: npx skills add https://github.com/zaid-khan-code/learnHub-ai-powered-online-learning-platform-lms --skill tailwind-v4-shadcn-zaid-khan-code

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill removes the guesswork from setting up Tailwind CSS v4 with shadcn/ui, especially when theme colors, dark mode, or migration details keep breaking a project.

Core Features & Use Cases

  • Production setup patterns: Provides a CSS-first Tailwind v4 structure that works with React and Vite.
  • Theme and dark mode support: Shows how to define semantic color tokens, wire up a ThemeProvider, and switch themes reliably.
  • Troubleshooting and migration help: Covers common v4 failures like missing utilities, duplicate base layers, broken color variables, and v3-to-v4 migration issues.
  • Use case: A team upgrading a React app can use this Skill to replace brittle Tailwind config-based theming with a stable, production-ready shadcn/ui setup.

Quick Start

Use this skill to configure your React project with Tailwind v4, shadcn/ui, CSS variables, and dark mode using the skill’s recommended file structure and setup order.

Frequently Asked Questions about tailwind-v4-shadcn

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

FAQPage Schema
How do I configure Tailwind CSS v4 with shadcn/ui using CSS variables in React and Vite?▼

To configure Tailwind CSS v4 with shadcn/ui, use a CSS-first setup that replaces tailwind.config.ts, defines root-level :root and .dark variables, and maps semantic color tokens via @theme inline for your React and Vite project.

Why does my Tailwind v4 dark mode setup break when migrating from v3?▼

Tailwind v4 dark mode breaks during migration due to missing CSS variables or duplicate base layers. Fix this by removing the old tailwind.config.ts, applying CSS-first configuration, and ensuring proper root-level :root and .dark variable mapping.

Do I need to remove tailwind.config.ts to use Tailwind CSS v4 features with shadcn/ui?▼

Yes, you need to remove tailwind.config.ts to use Tailwind CSS v4 features with shadcn/ui, because v4 shifts to a CSS-first configuration model using the @theme inline directive and @tailwindcss/vite plugin instead of JavaScript config files.

How do I fix broken color variables and missing utilities in shadcn/ui after upgrading to Tailwind v4?▼

Fix broken color variables and missing utilities in shadcn/ui by verifying your @theme inline mapping, resolving duplicate base layers, and ensuring your ThemeProvider workflow correctly applies semantic color tokens defined in your :root and .dark CSS blocks.

What is the best way to set up a ThemeProvider for Tailwind v4 semantic color tokens?▼

The best way to set up a ThemeProvider for Tailwind v4 semantic color tokens involves defining root-level :root and .dark CSS variables, wiring up the ThemeProvider in React, and mapping these tokens through the @theme inline directive for reliable theme switching.

Does @tailwindcss/vite work with shadcn/ui for dark mode and theming?▼

@tailwindcss/vite works with shadcn/ui for dark mode and theming by enabling a CSS-first configuration approach where you define semantic color tokens, map them via @theme inline, and manage theme switching through a React ThemeProvider.