Mani element restrictions

The main element is nested in the body element,
below the header element.
The main element may have an h1 element nested in it,
that h1 element may be immediately followed by a paragraph element.
Are article or section or div elements thereafter nested in the main or
below the main but ofcourse nested in the body? I’m trying to understand
how much is allowed to be covered in the main element. Can it be the hero section only or what?

Hello, can you post a link to the challenge and your code as well?

Sorry robheyays, I am only trying to find out what is a “main” element allowed to contain on a webpage generally. The priciple or standard use of the “main” element. Can it have many sections inside it or it should only hold an h1 and paragraph presenting whatever. How do I determine “main” then ‘section’ in the “main” or outside the main. My code works well, my problem is proper semantic and hierachy usage of main versus other container elements, especially sections.
I’m sorry, I think I should research it myself. Very sorry and deeply appreciative of your effort.

1 Like

Best to check the docs. Most people answering would have to check the docs as well.

https://www.w3schools.com/tags/tag_main.asp

https://www.geeksforgeeks.org/html-main-tag/

https://developer.mozilla.org/en-US/docs/Web/HTML/Element/main

1 Like