fix(nuxt): clear loading indicator on unmount (#19340)

This commit is contained in:
Alexander Lichter 2023-02-28 20:18:47 +01:00 committed by GitHub
parent 32f6cb27b7
commit 639189ca88
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -32,7 +32,7 @@ export default defineComponent({
const nuxtApp = useNuxtApp()
nuxtApp.hook('page:start', indicator.start)
nuxtApp.hook('page:finish', indicator.finish)
onBeforeUnmount(() => indicator.clear)
onBeforeUnmount(indicator.clear)
return () => h('div', {
class: 'nuxt-loading-indicator',