Submitted over 3 years agoA solution to the FAQ accordion card challenge
FAQ accordion card with Javascript
@snehamoybag

Solution retrospective
This is my second time uploading this challenge. I've managed to add some transition effect to the accordion using the element.style.maxHeight = element.scrollHeight + "px" , but this effect only works when the accordion opens..but doesn't work when its closing. I'll be super grateful if anybody can teach me how to do it. 🙇🏾♂️
Update : made the javascript cleaner and added a little bit of transition effect using the opacity property
Code
Loading...
Please log in to post a comment
Log in with GitHubCommunity feedback
No feedback yet. Be the first to give feedback on Snehamoy Bag'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