Loading
Current section: Preparing for Tailwind v4 6 exercises
Problem

Integrating Tailwind v4 with Vite

Loading exercise

Transcript

00:00 Tailwind v4 can be installed in many different ways. There is a PostCSS plugin, there is a Vite plugin, and a standalone CLI. Now, because in this workshop we're already using a Vite app, we're going to install the Vite plugin. And in this first segment, you're going to go through the process of doing just that. The dependencies are already installed in this app.

00:18 So we have Tailwind version 4 and the Tailwind Vite plugin. And so what you're going to have to do is register the Vite plugin in the Vite config and then import Tailwind CSS in the CSS file with the new syntax. If you're using VS Code, you also want to make sure that you upgrade the version of the Tailwind IntelliSense extension. All right, enough talking, let's get going.