CSS-CASCADE Flashcards
What are the four components of “the Cascade”?
The four components of "the Cascade" are: (Priority order [Highest to Lowest]) 1. !important 2. Specificity 3. Source Order 4. Inheritance
What does the term “source order” mean with respect to CSS?
The order CSS property sets the order to lay out an item in a flex or grid container. Items in a container are sorted by ascending order value and then by their source code order.
How is it possible for the styles of an element to be applied to its children as well without an additional CSS rule?
Inheritance makes it possible for the styles of an element to be applied to its children as well without an additional CSS rule.
List the three selector types in order of increasing specificity.
The three selector types in order of increasing specificity are:
- element name
- class
- id
Why is using !important considered bad practice?
Using “!important” is bad practice because it’s too powerful!