Skip to content

Commit

Permalink
Merge branch 'nuxt:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
Ibochkarev authored Jun 11, 2024
2 parents 76d43fc + 14fecc9 commit 7c7b358
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/nuxt/src/app/composables/ready.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ export const onNuxtReady = (callback: () => any) => {

const nuxtApp = useNuxtApp()
if (nuxtApp.isHydrating) {
nuxtApp.hooks.hookOnce('app:suspense:resolve', () => { requestIdleCallback(callback) })
nuxtApp.hooks.hookOnce('app:suspense:resolve', () => { requestIdleCallback(() => callback()) })
} else {
requestIdleCallback(callback)
requestIdleCallback(() => callback())
}
}

0 comments on commit 7c7b358

Please sign in to comment.