Tailwind CSS interview question · Most asked

What changed in Tailwind CSS v4 compared with v3?

Create a free account to save this page, take notes and track your progress. Sign in

Summary

A new, much faster engine; CSS-first configuration (@import "tailwindcss" and @theme instead of tailwind.config.js and @tailwind directives); automatic content detection; OKLCH colours; built-in container queries; modern CSS features (cascade layers, @property, color-mix). Several defaults and names changed: border is currentColor, ring is 1px, shadow/rounded/blur scales shifted, opacity utilities removed, outline-none became outline-hidden.

Longer Answer

Upgrade with npx @tailwindcss/upgrade and compare screenshots; v4 needs Safari 16.4+, Chrome 111+, Firefox 128+.

Key Points

  • Faster engine.
  • CSS-first config.
  • Automatic detection.
  • Changed defaults and renames.

Deep dive: Tailwind CSS Tutorial: Upgrading from Tailwind v3 to v4

Explanation

What interviewers look for

Both the big ideas and the breaking details.

More most-asked Tailwind CSS questions

← All Tailwind CSS questions

Was this page helpful?