@correlucas
Posted
๐พHello @TiagoLuch, Congratulations on completing this challenge!
Great code and great solution! Iโve few suggestions for you that you can consider adding to your code:
1.The HTML structure is fine and works, but you can reduce at least 20% of your code by cleaning the unnecessary elements, you start cleaning it by removing some unnecessary <div>
. For this solution you wrap everything inside a single block of content using <div>
or <main>
(better option for accessibility) and put inside the whole content <img>
/ <h1>
and <p>
.
<body>
<main>
<img src="./images/image-qr-code.png" alt="QR Code Frontend Mentor" >
<h1>Improve your front-end skills by building projects</h1>
<p>Scan the QR code to visit Frontend Mentor and take your coding skills to the next level</p>
</main>
</body>
2.The main heading has the tag <p>
, in this case, you should replace it with <h1>
since this heading is the main title on this page. Remember that every page should have one <h1>
to declare which is the most important title and that you should follow the hierarchy using the heading sequence (h1, h2, h3, h4, h5)
and never jump a level.
3.Use <main>
instead of a simple <div>
this way you improve the semantics and accessibility showing which is the main block of content on this page. Remember that every page should have a <main>
block and that <div>
doesn't have any semantic meaning.
4.Use relative units as rem
or em
instead of px
to improve your performance by resizing fonts between different screens and devices. These units are better to make your website more accessible. REM does not just apply to font size, but to all sizes as well.
โ๏ธ I hope this helps you and happy coding!