Hast thou been tempted to use !important to make your CSS "work"? Or wondered why your styles weren't working?
Here's a quick write-up of how the CSS Cascade works, so we can all learn it once and for all!





https://wattenberger.com/blog/css-cascade …





pic.twitter.com/KESFx4mQR1
-
Show this thread
-
this one took a good amount of research and spec digging, which I'm hoping is correlated with helpfulness! I love learning new things while writing an article.
4 replies 0 retweets 26 likesShow this thread
Replying to @Wattenberger
A fun connection you may find interesting: resolving CSS properties to rules follows a similar structure to resolving methods to classes. http://willcrichton.net/notes/specificity-programming-languages/ … For languages with multiple inheritance, the resolution process can be similarly complicated as CSS
0 replies
1 retweet
1 like
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.
cognitive psychology. PhD