forEach终止循环的方法

list.forEach(arg => {
  if (arg.event_state === '0') {
    this.$message.warning('警告')
    throw new Error()  // 终止跳出循环
  }
})
原文地址:https://www.cnblogs.com/qianxiaoniantianxin/p/15122231.html