This commit is contained in:
2025-09-30 02:02:56 -06:00
parent a346e30777
commit 1cf09ee640
7 changed files with 425 additions and 81 deletions

View File

@@ -0,0 +1,22 @@
export default defineNuxtPlugin(() => {
// This plugin ensures the loading screen is properly hidden when the app is ready
if (process.client) {
// Listen for when the app is fully hydrated
const checkReady = () => {
// Wait for next tick to ensure DOM is painted
requestAnimationFrame(() => {
setTimeout(() => {
document.documentElement.classList.add('nuxt-ready')
}, 50)
})
}
// Multiple triggers to ensure loading screen is hidden
if (document.readyState === 'complete') {
checkReady()
} else {
window.addEventListener('load', checkReady)
}
}
})