skip to Main Content

Javascript – Node JS: Loop round grouped by array

I've got data like this [ [ '@test','1.2.6-unstable' ], [ '@test','1.3.2-unstable' ], [ '@test','1.4.6-unstable' ], [ '@test2','4.0.1-unstable' ], [ '@test2','4.0.2-unstable' ], [ '@test2','4.0.3-unstable' ], [ '@test3','2.2.0-unstable' ], [ '@test3','2.2.3-unstable' ], [ '@test3','2.2.9-unstable' ], ... ] and I'm trying to group…

VIEW QUESTION

Javascript – How to assign different audio to different buttons after clicked event

<h1 id="title">Drum 🥁 Kit</h1> <div class="set"> <button class="w drum">w</button> <button class="a drum">a</button> <button class="s drum">s</button> <button class="d drum">d</button> <button class="j drum">j</button> <button class="k drum">k</button> <button class="l drum">l</button> </div> var tekan = document.querySelectorAll(".drum"); tekan.forEach(drum => { drum.addEventListener("click", play); }) function play()…

VIEW QUESTION
Back To Top
Search