feat(fullstack): Add server health check with overlay

This commit is contained in:
2025-09-05 15:24:51 +02:00
parent 6090d543c1
commit 79c0734bd2
10 changed files with 201 additions and 8 deletions

View File

@@ -0,0 +1,13 @@
export default defineNuxtPlugin(() => {
// This plugin runs only on the client side to avoid issues with server-side rendering
if (import.meta.client) {
// Initialize server health monitoring as soon as the client is ready
const { startPeriodicHealthCheck } = useServerHealth()
// Start the health check with a 1-minute interval
// This ensures the health check starts even if app.vue's onMounted hasn't fired yet
nextTick(() => {
startPeriodicHealthCheck(60000)
})
}
})