class attribute
noun
say it: “KLASS AT-ri-byoot” /klæs ˈætrɪbjuːt/
An attribute that puts an element into one or more named groups, so the same style or behavior can apply to every element in the group.
What is class attribute?
class attribute — An attribute containing one or more reusable class names for an element.
<p class="daily-special">Tomato soup</p>
In a sentence
- “Every sold-out drink on the menu has the class sold-out, so one CSS rule grays them all out.”
Level: Novice · More CSS terms at this level
Updated