Subscribe on changes!

SFC styles are on top of bundled styles

avatar
May 5th 2020

I'm using Vite with Postcss and Tailwind. After bundling my vite app, styles defined in SFCs are prepend to bundled styles. This is causing tailwind's reset classes to take higher priority than component's styles. If I mark my styles scoped they are takes higher priority but of course scoped styles are not for that.

avatar
May 6th 2020

Can you privider a repo for this.

avatar
May 19th 2020

Closing (stale)

avatar
Jul 18th 2020

This issue is happens when style is defined in App.vue.

Here it is a tailwind repro https://github.com/sibbngheid/issue-52/commit/43b97926db14874906bf9530e85e594dd78ac14d Cloned from https://github.com/posva/vite-tailwind-starter

Actually same issue happens on create-vite-app too. After build, styles defined in App.vue are comes before the styles in index.css