Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

FAQ accordion card component made with vanilla JS and flexbox

@elizabethrsotomayor

Desktop design screenshot for the FAQ accordion card coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


I struggled with sizing the image/background to fit the mockup. In order to achieve the accordion effect without the use of JavaScript, would the details tag be used? Also I'm not sure about my use of the getElementById for accordion menu items being indexed by number (for instance, if there were a lot more items to be added). Thank you for any suggestions to make my code more concise/clean!

Community feedback

Please log in to post a comment

Log in with GitHub
Discord logo

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