50projects50days/animated-navigation/script.js
2020-09-06 15:13:20 -04:00

5 lines
164 B
JavaScript

const toggle = document.getElementById('toggle')
const nav = document.getElementById('nav')
toggle.addEventListener('click', () => nav.classList.toggle('active'))