Rule Sets

A rule set (also called a rule) comprises a selector followed by a declaration block; the rule set applies the declarations listed in the declaration block to all elements matched by the selector.

Here’s an example of a rule set:

h2 {
  color: #666;
  font-weight: bold;
}

User-contributed notes

Add a note

To post a note on this topic, please log in with your SitePoint username and password. If you don't have an account yet, you can create a new account for free.

Related Products