fix(vue3): Rename "destroyed" hook

This commit is contained in:
Tixie 2021-10-14 02:41:39 +02:00
parent 37e4fbe2d4
commit ad7029e0e3
7 changed files with 5 additions and 11 deletions

5
package-lock.json generated
View file

@ -1377,11 +1377,6 @@
"resolved": "https://registry.npmjs.org/@types/parse-json/-/parse-json-4.0.0.tgz",
"integrity": "sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA=="
},
"@vue/compat": {
"version": "3.2.20",
"resolved": "https://registry.npmjs.org/@vue/compat/-/compat-3.2.20.tgz",
"integrity": "sha512-ZbdYtVegOS4wgeHzlnYz7Q9j9NLYF083i5pK9UB1P11vTSVUqozDlPSo4V1ODkluuFED7aGfFCHm7KmTJrnORA=="
},
"@vue/compiler-core": {
"version": "3.2.20",
"resolved": "https://registry.npmjs.org/@vue/compiler-core/-/compiler-core-3.2.20.tgz",

View file

@ -11,7 +11,6 @@
"lint-fix": "eslint --ext .js,vue . --fix"
},
"dependencies": {
"@vue/compat": "^3.2.20",
"folktale": "^2.3.2",
"generic-pool": "^3.7.1",
"gif-writer": "^0.9.3",

View file

@ -23,7 +23,7 @@ export default {
mounted () {
document.addEventListener('visibilitychange', this.handleVisibilityChange)
},
destroyed () {
unmounted () {
document.removeEventListener('visibilitychange', this.handleVisibilityChange)
}
}

View file

@ -64,7 +64,7 @@ export default {
mounted () {
this.startPreview()
},
destroyed () {
unmounted () {
this.stopPreview()
}
}

View file

@ -23,7 +23,7 @@ export default {
mounted: function () {
document.body.classList.add('layoutOverlay-body')
},
destroyed: function () {
unmounted: function () {
document.body.classList.remove('layoutOverlay-body')
}
}

View file

@ -178,7 +178,7 @@ export default {
this.ensureCamera()
},
destroyed: function () {
unmounted: function () {
document.body.classList.remove('capture-body')
document.removeEventListener('visibilitychange', this.handleVisibilityChange)
}

View file

@ -125,7 +125,7 @@ export default {
this.fillGIF()
}
},
destroyed () {
unmounted () {
this.emptyGIF()
}
}