瀏覽代碼

清理定时器,避免死循环

shaogen1995 1 年之前
父節點
當前提交
688a79e22e
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      src/components/PaintingDetailBox.vue

+ 1 - 0
src/components/PaintingDetailBox.vue

@@ -100,6 +100,7 @@ onMounted(() => {
           }
         }
       }, 600)
+      clearInterval(tiemrr.value)
       tiemrr.value = setInterval(() => {
         console.log('interval')
         if (zhouMove.value >= 99) clearInterval(tiemrr.value)