scrimba
JSC24
Go Pro!Bootcamp

Bootcamp

Study group

Collaborate with peers in your dedicated #study-group channel.

Code reviews

Submit projects for review using the /review command in your #code-reviews channel

AboutCommentsNotes
JSC24
Expand for more info
index.js
run
preview
console
const crew = document.getElementById("crew")
const btn = document.getElementById("btn")
const audio = new Audio("hohoho.mp3")

let counter = 4;
// Task:
// - Write a function to launch the sleigh!
// - See CSS for more tasks.

// Stretch goals:
// - Add a cheering sound when the sleigh takes off.
// - Add a countdown to the launch time.

btn.addEventListener('click', launch)

function stopAudio(){

}

function launch() {
crew.classList.add("slide-out-blurred-top")
setTimeout(()=> {audio.play()
setTimeout(()=> {
audio.pause();
audio.currentTime = 0;
}, 4000)
}, 100);
}

Console
/index.html
LIVE