Tabs: It's Complicated™

added by JavaScript Kicks
4/19/2019 8:40:24 PM

294 Views

I've said before one quick and powerful thing you can learn as a front-end developer just getting starting with JavaScript is changing classes. const button = document.querySelector(".my-button"); const element = document.querySelector(".content"); button.addEventListener("click", function() { element.classList.toggle("sparkles"); }); We could use that skill to build some tabs, right? Right.


0 comments