2
0
mirror of https://github.com/tenrok/vue-meta.git synced 2026-06-23 00:20:34 +03:00

example: cleartimeout in ssr example

This commit is contained in:
pimlie
2019-09-12 12:11:36 +02:00
parent 20ac99503d
commit 9225d5e7fe
+4 -1
View File
@@ -30,9 +30,12 @@ const ChildComponent = {
} }
}, },
mounted () { mounted () {
setInterval(() => { this.interval = setInterval(() => {
this.date = new Date() this.date = new Date()
}, 1000) }, 1000)
},
destroyed () {
clearInterval(this.interval)
} }
} }