I\'m trying to run multiple timers given a variable list of items. The code looks something like this:
var list = Array(...); for(var x in list){ setInt
You can combine forEach and setTimeout to loop over the array with the interval.
forEach
setTimeout
let modes = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]; let interval = 1000; //one second modes.forEach((mode, index) => { setTimeout(() => { console.log(mode) }, index * interval) })