FAQ accordion with JavaScript interaction

Solution retrospective
I learned how to use this.closest()
with querySelector()
aside the other few JS methods I had known before, I'm proud of that, will put more practice into loops, differently next time
Lots of challenges because this actually my first time playing with loops, the example I had in class wasn't very much realistic for me to relate with what I was trying to do on this challenge, so the more I tried to make some sense out of it, the more it seemed confusing for me lol, I had to reach out to a friend and he helped me through it, explaining how the for
loop would solve my problem and how to use it if not, I was initially thinking of creating seperate instructions/functions each for my icons which would have made my code much longer and repeated. All thanks to my friend, I was able to use the for
loop to iterate through and solve my problem without code repeatedness
I'd generally appreciate reviews about anything that needs/can be made better
Please log in to post a comment
Log in with GitHubCommunity feedback
No feedback yet. Be the first to give feedback on R4PH431's solution.
Join 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