Skip to content

Commit 30696cd

Browse files
committed
add eventlistner
1 parent 2771408 commit 30696cd

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

RotatingNavigation/script.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
const open = document.getElementById('open');
2+
const close = document.getElementById('close');
3+
const container = document.querySelector('.container');
4+
5+
open.addEventListener('click', () => container.classList.add('show-nav'));
6+
close.addEventListener('click', () => container.classList.remove('show-nav'));

0 commit comments

Comments
 (0)