Design comparison
SolutionDesign
Solution retrospective
What are you most proud of, and what would you do differently next time?
I'm proud that I used anchor positioning for the first time (using it on the mobile hamburger menu). I strengthened my a11y code with strong use of semantic headers.
What challenges did you encounter, and how did you overcome them?ensured the page was SR friendly
Community feedback
- @elisilkPosted about 1 month ago
Hi 👋 @35degrees,
Congrats on a very nice solution. 👏 I like how you implemented the hamburger menu using only CSS. Very cool!
If you are up for diving in just a little further 🤿, I'd suggest a few things:
- First, when you have different versions of the same image, like you do for the banner image in this challenge, consider using the
<picture>
element. This will help ensure the correct image loads on the user's device, saving bandwidth and boosting performance. For example:
<picture> <source media="(min-width: 768px)" srcset="{desktop image path here}"> <img src="{mobile image path here}" alt="{alternative text here}"> </picture>
- Second, when I open your solution on my browser and move to a smaller viewport width, for me, the height of the content extends beyond the viewport height and there is scrolling down but not up. And so the top of content (the nav and part of the banner image) is cut off and not accessible. One option to fix this would be to adjust how you set the
height
attribute of your.main-container
in your CSS. Specifically, try changing theheight
attribute to instead bemin-height
. Doing that will allow the container to fill up the entire viewport height (as you had it originally), but now it will also allow themain-container
it to extend beyond that viewport height when needed. Like this:
.main-container { min-height: 100vh; }
Anyway, just some ideas to consider if you are thinking about improving on this solution. 🤔
Great job overall! Happy coding. 💻
Eli
Marked as helpful0 - First, when you have different versions of the same image, like you do for the banner image in this challenge, consider using the
- @35degreesPosted about 1 month ago
Very helpful feedback, I appreciate the insight and support!
0
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