FrontendDeveloper.in

CSS question detail

What is specificity in CSS?

Specificity decides which selector wins when multiple rules target the same element.

Order from weaker to stronger is roughly: element selectors, class/attribute/pseudo-class selectors, then ID selectors, and finally inline styles.

Back to all CSS questions
Get LinkedIn Premium at Rs 399