Chapter 5. Semantics: Making Sense of Styles

Semantics: Making Sense of Styles

When we speak to each other, we understand as much from the context of our words as from the words themselves. To be understood, we need to be clear about the context of our statements. We use semantics to do this, putting ideas together in a logical manner. We don’t think about it, it’s an instinct like breathing—we do it all the time.

In CSS, where you place your styles defines where and how they will be applied. You need to understand how styles cascade down the document, and how to apply different styles depending on the medium. With a bit of practice, the semantics of CSS will also become as instinctual ...

Get Speaking in Styles: Fundamentals of CSS for Web Designers now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.