Learn Typography by Building a Nutrition Label - Step 7

I think I have the code right, I need to wrap the h1 and p elements in a div with the class of label. I’ve tried doing each one separately and tried wrapping them all in one tag but I can’t get it to work…

<!-- file: index.html -->
<!DOCTYPE html>
<html lang="en">
    <meta charset="UTF-8">
    <title>Nutrition Label</title>
    <link href="https://fonts.googleapis.com/css?family=Open+Sans:400,700,800" rel="stylesheet">
    <link href="./styles.css" rel="stylesheet">
    <div class:"label">
      <h1>Nutrition Facts</h1>

      <p>8 servings per container</p>
      <p>Serving size 2/3 cup (55g)</p>
/* file: styles.css */
html {
  font-size: 16px;

body {
  font-family: 'Open Sans', sans-serif;

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/ Safari/537.36

Challenge: Learn Typography by Building a Nutrition Label - Step 7

Link to the challenge:


Haha! I had just realized this too! Thank you for your help!

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.