Design comparison
Community feedback
- @ldgPosted over 1 year ago
Hi Alexander,
I wanted to comment on your javascript, I found it well organized and easy to follow. Your code in general is nicely organized, and very readable. I still struggle with Javascript so I appreciate the clarity of your code.
I also have two minor suggestions:
1/ I notice on desktop view, your submenu container will expand from a hover event on menu links that are wider. This creates an unintended expansion of the dropdown menu. I think you can resolve that by setting wider, fixed width on the
.sublinks-container
. That will stop the wobble effect when passing the cursor over links.2/ It might be nice to set a css transition on your buttons, just something slow down the hover effect, it will make that interaction feel a bit smoother, less jarring. I think that will give your solution a more polished look.
Marked as helpful0@alexander-hergertPosted over 1 year agoHello Scott, thank you for the compliments. In fact trying to keep the code more organized was the true challenge ;) I hope the structure helped you to follow it and get some ideas. Its still very basic and I think I can work even more on the structure and comments in future.
Yes this project is not perfect yet and has here and there some flaws which I will fix in later iterations when revisiting it again. But for now I thought it does the job :D Javascript can be challenging in the beginning. But I can promise you that you can learn it if you simply daily use it and try different things with it. Also reading about the concepts of it helped me to understand it deeper but I would not consider me to be a master in it yet too ;) By far not...
Also even if you do understand JS well, a messy code is not fun to work with. So let us pay attention on clean code. This is what matters most if you work with other people.
1@ldgPosted over 1 year ago@ChVoS1989
Absolutely, my suggestions where mostly on extra polish. I think you succeeded in your real challenge to write more organized code!
I appreciate the words of encouragement with Javascript. I think you're correct, daily challenges are really the way to learn. I'll keep working at it, and hopefully understand it better.
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