Skip to content

How to override the theme's defaults in plain css or tailwind classes? #2257

Answered by Sarenor
AnatoleLucet asked this question in Q&A
Discussion options

You must be logged in to vote

The problem is that the Skeleton h1 classes are as specific as tailwind classes, but will always be defined after Tailwind classes in the stylesheet, due to how Tailwind Plugins work.

That means that they will always have a higher specificity, since the class that's defined last will win if there's no other differentiator.

So the only way to override specific parts of Skeleton classes that you're using is by using the Tailwind-! syntax like so !font-thin.

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@AnatoleLucet
Comment options

@Sarenor
Comment options

@AnatoleLucet
Comment options

Answer selected by AnatoleLucet
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants