摘要: 1.data中定义 timer: null 2.methods中写方法 this.timer = setInterval(function () { // 你的逻辑判断 }, 2000) 3.beforeDestroy 实例销毁之前调用 清除定时器 beforeDestroy() { clearIn 阅读全文
posted @ 2020-11-18 10:28 凉城i 阅读(883) 评论(2) 推荐(0) 编辑