source order
The order in which CSS rules appear; when everything else ties, the rule that comes later wins.
In more detail
Source order is the final tie-breaker of the cascade, which makes the result deterministic. It also decides the order of cascade layers declared with @layer.
Related terms
- CSS cascade — The CSS process that decides which of several competing rules sets a property on an element.
- specificity — The weight the browser gives a CSS selector, used to decide which rule wins when two set the same property.
Taught in
- The Cascade Algorithm: Specificity, Inheritance And Source Order — Frontend Architecture & Web Platform
- CSS Cascade Layers: Taming Specificity Wars with @layer — Frontend Architecture & Web Platform