Tailwind Intellisense - WebStorm

I hope this guide will help webstorm users. WebStorm version - 2023.1 , Tailwindcss - 3.3.0 The problem: Tailwind Intellesense doesn't work at all. Solution: - Change tailwind config file extension from .ts to .cjs and change code to this one:
/** @type {import('tailwindcss').Config} */
const config = {
content: ["./src/**/*.{js,ts,jsx,tsx}"],
theme: {
extend: {},
},
plugins: [],
};

module.exports = config;
/** @type {import('tailwindcss').Config} */
const config = {
content: ["./src/**/*.{js,ts,jsx,tsx}"],
theme: {
extend: {},
},
plugins: [],
};

module.exports = config;
Don't forget to save the file. And add to tsconfig.json:
"exclude": ["node_modules", "tailwind.config.cjs"]
"exclude": ["node_modules", "tailwind.config.cjs"]
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server