Design comparison
SolutionDesign
Solution retrospective
Hello, It was tiring to make this js component but it's a victory for me. I have some questions :
- how to match event with our tag (li, button, input) using Event Delegation ? i have used this : if (event.target.classList[0] === document.querySelector(".card_rating_rate").classList[0]) ...
- what if we have to replace a div's content with another ? should we to generate html with js or hidden in html the other div and switch the first one to the second ? i have generate html with js, it's working but i don't know if it's really good to doing that.
Let me know if you have some question about my solution to this challenge. Thank you.
Community feedback
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