Back to Freecodecamp

Step 8

curriculum/challenges/english/blocks/learn-basic-css-by-building-a-cafe-menu/5f344fc1520b6719f2e35605.md

latest1.1 KB
Original Source

--description--

There will be two sections on the menu, one for coffees and one for desserts. Add a section element within the main element so you have a place to put all the coffees available.

--hints--

You should have an opening <section> tag.

js
assert(code.match(/<section\s*>/i));

You should have a closing </section> tag.

js
assert(code.match(/<\/section\s*>/i));

You should not change your existing main element. Make sure you didn't delete the closing tag.

js
assert.lengthOf(document.querySelectorAll('main'),1);

Your section element should be within your main element.

js
const main = document.querySelector('main');
const section = document.querySelector('section');
assert(section.parentElement === main);

--seed--

--seed-contents--

html
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8" />
    <title>Cafe Menu</title>
  </head>
  <body>
--fcc-editable-region--
    <main>
      <h1>CAMPER CAFE</h1>
      <p>Est. 2020</p>
    </main>
--fcc-editable-region--
  </body>
</html>