Design comparison
Solution retrospective
This solution uses no JS, instead going for a pure CSS mobile menu. The drawback is that it uses :has, which is unsupported by Firefox. I did not craft a fallback for Firefox.
There is only one breakpoint (at 1024px) for responsiveness. Basically, it toggles between a desktop/tablet view and a mobile/small tablet view.
Fun project.
Community feedback
- P@momin-riyadhPosted over 1 year ago
Good Job! Why did you add a flex property style in the body tag? Suppose you have many pages that will be rendered in the body tag. Then flex property may not be necessary for the rest!
body { min-height: 100dvh; display: flex; justify-content: center; }
Moreover, you need to subscribe, and to get started, follow this link. It'll take you to the course's website, where you can sign up and start your JavaScript learning journey. Don't worry; the course is beginner-friendly and designed to help you grasp the fundamentals.
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