Design comparison
Solution retrospective
Is there any errors in my code?
Community feedback
- @JaneMorozPosted over 1 year ago
Hey! Your solution is great 🤩
The only things I've noticed are some accessibility issues:
- You can wrap the main content (which is QR Code in this case) into the
main
tag or replace existingdiv
tag withmain
. - Also usually the page should have
h1
tag. You haveh2
, I guess you decided to use it because it has desirable font-size but you can styleh1
.
Overall everything is great and I like that it is responsive ☺️
Keep it up! And good luck 🍀
Marked as helpful1@KoliaKPosted over 1 year ago@JaneMoroz thanks in advance for your reply. Would you give me more details regarding wrapping the QR in the main tag? I mean, what would improve by replacing div with main?
1@JaneMorozPosted over 1 year ago@KoliaK
Something like this:
<body> <div class="container"> <main class="card"> <img src="images/image-qr-code.png" alt="image-qr-code" /> <div class="text"> <h1>Improve your front-end skills by building projects</h2> <p>Scan the QR code to visit Frontend Mentor and take your coding skills to the next level</p> </div> </main> </div> </body>
Usually your page must have
header
,main
andfooter
. But in this challenge there's only QR code, so only havingmain
makes sense.main
is for the main content of the page, it's some sort of unique content, you can read more here. Remember there could be only onemain
tag per page.header
can represent banner landmark of the web page. This is usually placed at the top of the page and in most cases you'll have logo and navigation inside. You can usually see it on every page.If you have
article
elements, you can haveheader
in each as well becauseheader
represents a container for introductory content.footer
element typically contains: copyright information, contact information, etc. And you can usually see it on every page as well. As like withheader
you can also usefooter
inside thearticle
element too.All this tags are semantic HTML tags. Using semantic HTML tags improves accessibility of the web page, which is important for being use-friendly for screen-readers and indexing bots.
Marked as helpful0@KoliaKPosted over 1 year ago@JaneMoroz got it! Thank you so much for these details! I couldn't realize what you meant without the code. I haven't code anything in many years and now I'm trying to retrieve the skills.
1 - You can wrap the main content (which is QR Code in this case) into the
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