CSS isn't magic

Share this post

User's avatar
CSS isn't magic
What does :not(class) make useful?

What does :not(class) make useful?

Stas Melnikov's avatar
Stas Melnikov
Jul 02, 2025
∙ Paid

Share this post

User's avatar
CSS isn't magic
What does :not(class) make useful?
Share
A wrong code. I use 2 rule. At first I define margins for the ul elements. Then I reset it for the ul elements with the list class. A correct code. I make the same but I use the ul:not([class])

How do you define basic typography styles? If you set styles via the type selector and reset via a class, I'll offer to do it without a reset. Just use :not([class])!

Keep reading with a 7-day free trial

Subscribe to CSS isn't magic to keep reading this post and get 7 days of free access to the full post archives.

Already a paid subscriber? Sign in
© 2025 Stas Melnikov
Privacy ∙ Terms ∙ Collection notice
Start writingGet the app
Substack is the home for great culture

Share