Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var startButton = document.querySelector('.start-button');
- startButton.addEventListener("click", movement);
- function movement() {
- function markup(i) {
- return function () {
- console.log(i);
- markupLeft[i].classList.toggle('markup-lighting');
- }
- }
- for(var i = 0;i<markupLeft.length; i++) {
- setTimeout(markup(i), i * 100);
- }
- }
Add Comment
Please, Sign In to add comment