Design comparison
Solution retrospective
Should I use article or section tags instead of div as children of my main tag?
This was my first time using Sass. Am I nesting when I probably shouldn't or doesn't it actually matter? I really like how nesting makes my stylesheet look so clean.
Community feedback
- @HassiaiPosted almost 2 years ago
Replace <p class="first-text"> with <h1> to fix the accessibility issues.
To center .container on the page using flexbox, replace the height in the main with min-height: 100vh.
Give h1 and p the same font-size of 15px and the same margin-left, margin-right and margin-top values. Give p a margin bottom value.
Hope am helpful.
Well done for completing this challenge. HAPPY CODING
Marked as helpful1 - @sandro21-glitchPosted almost 2 years ago
Hi Joseph
The choice between using article or section tags versus div tags depends on the purpose of the content being marked up.
The article element represents a self-contained composition in a document, such as a blog post or a forum post, that should make sense on its own.
The section element represents a standalone section of a document, such as chapters, headings, or any other thematic grouping of content.
If the content within the main tag is a self-contained composition or a standalone section, it would be appropriate to use either the article or section elements, respectively.
If the purpose of the content within the main tag is more structural in nature, it may be more appropriate to use a div element.
Happy Coding
1
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord