Disconnect IOs on destroy

This commit is contained in:
2021-11-17 21:51:41 +01:00
parent df1e6f7311
commit 1b181b92fc
2 changed files with 3 additions and 2 deletions

View File

@@ -105,7 +105,7 @@
return () => { return () => {
if (globe) { if (globe) {
globe.destroy() globe.destroy()
observer.unobserve(globeEl) observer.disconnect()
} }
} }
}) })

View File

@@ -67,9 +67,10 @@
}) })
observer.observe(listEl) observer.observe(listEl)
// Destroy // Destroy
return () => { return () => {
observer.disconnect()
} }
}) })
</script> </script>