@GretaLiSubmitted over 2 years ago
Hi there,
Initially, I found the dropdown menu very challenging while trying pure javascript.
Because .querySelector
only chooses the very first element with the same class name, I could only control the first dropdown menu by id.
Then I turned to use jQuery, I use $(this)
to control which menu should be dropdown.
Still, I'd like to know how to achieve this feature with only JS. 🥲🥲