diff --git a/src/vue-pdf-embed.vue b/src/vue-pdf-embed.vue index 65c65e1..367710b 100644 --- a/src/vue-pdf-embed.vue +++ b/src/vue-pdf-embed.vue @@ -137,9 +137,11 @@ export default { this.render() }, beforeDestroy() { + this.$el.querySelectorAll('canvas').forEach(releaseCanvas) this.document?.destroy() }, beforeUnmount() { + this.$el.querySelectorAll('canvas').forEach(releaseCanvas) this.document?.destroy() }, methods: {