HTML & CSS Styling CoreLesson 16Free preview
Cascade & Inheritance
This lesson is part of Intro to HTML & CSS · All levels
Summary
Cascade is a CSS way of resolving conflict between rules based on order, source, specificity, and !important. Meanwhile, inheritance makes some property (such as color) inherited from mother to child. Understanding both of these allows you to guess which style the browser actually applies.
Key points
- Cascade: order, source, specificity, and !important determine the winner of the rule
- Properties of text such as color and font families are passed on to the child element
- Box properties such as border and padding are not inherited automatically
Full lesson
Code examples and quizzes
Full lessons, code examples, and quizzes are available to subscribers. 5 questions.