You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to contribute a Vite setup configuration necessary for using Tailwind CSS with Vite in the documentation. This configuration helps users set up Tailwind CSS efficiently in their Vite projects.
#1839
Closed
Nenepo opened this issue
Jul 13, 2024
· 4 comments
Hi! We already have a Vite guide on our site. The difference is that it creates a postcss config file by using the -p flag when calling init: https://tailwindcss.com/docs/guides/vite
Here is the Vite configuration I propose adding to the documentation:
import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';
import tailwindcss from 'tailwindcss';
export default defineConfig({
plugins: [react()],
css: {
postcss: {
plugins: [tailwindcss()],
},
},
});
The text was updated successfully, but these errors were encountered: