Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Tailwind css is not working in angular components

I have implemented tailwind css inside my angular project. Tailwind css is working at root level in project, but it is not working in the scss placed inside any components. Do I have to build every scss file inside the components? or is there any permanent solution for that?

like image 824
Hardi Shah Avatar asked Jun 04 '26 09:06

Hardi Shah


1 Answers

Update

Finally in Angular CLI v11.2 now supports tailwind out of the box

# install tailwind
npm install --save tailwindcss
# create `tailwind.config.js`
npx tailwindcss init

Then disable view encapsulation of the component
like image 157
Chellappan வ Avatar answered Jun 07 '26 15:06

Chellappan வ