vue循环遍历定时器
需要每隔1秒遍历如下代码,目前的问题是隔1秒后全部执行,请问怎么改进
startReview(){
console.log('start')
for(let i=0; i<this.handHistory.actions.preflop.length; i++){
setTimeout(()=>{
var currentSeat = this.handHistory.actions.preflop[i].seat
var bet = this.handHistory.actions.preflop[i].chip
var action = this.handHistory.actions.preflop[i].action
this.player[currentSeat].currentBet = bet
this.player[currentSeat].actionStatus = action
},1000)
}
}