freecoding.school100% FREE · NO SIGNUP
Markup CityISSUE #10 of 39

bold · italic · mark · the formatters

Tagg the BuilderVSThe Unclosed Tag
Tagg the Builder saysFormatting tags add meaning and emphasis: <strong>, <em>, <mark>, <small>, <del>, <ins>, and friends.

HTML has semantic formatting elements that carry meaning, not just looks. <strong> means importance (renders bold), <em> means emphasis (renders italic), <mark> highlights, <del> shows deleted text, <ins> inserted.

There are also pure-visual tags <b> and <i> — use the semantic ones when the meaning matters, since screen readers can announce them differently and search engines weigh them.

Power-ups you unlock

The Unclosed Tag attacks — common mistakes

Boss battleWrite a sentence that uses <strong>, <em>, and <mark> once each, then add a chemical formula with <sub> and an exponent with <sup>.

Example code

<!doctype html>
<html><head><meta charset="utf-8"></head>
<body>
  <p><strong>Important.</strong> A bit of <em>emphasis</em>, some <mark>highlight</mark>,
  a <del>mistake</del> <ins>correction</ins>, and H<sub>2</sub>O with E=mc<sup>2</sup>.</p>
</body></html>
▶ Open the interactive comic issue
‹ Inline Styles · Before Css ArrivedQuotations · Blockquote · Cite · Q ›