This commit is contained in:
padreug 2025-02-11 00:25:47 +01:00
parent 9cde9b5cf7
commit f3927b97a4
21 changed files with 8672 additions and 202 deletions

View file

@ -3,8 +3,23 @@ import App from './App.vue'
import router from './router'
import { i18n } from './i18n'
import './assets/index.css'
import { registerSW } from 'virtual:pwa-register'
const app = createApp(App)
app.use(router)
app.use(i18n)
// Simple periodic service worker updates
const intervalMS = 60 * 60 * 1000 // 1 hour
registerSW({
onRegistered(r) {
r && setInterval(() => {
r.update()
}, intervalMS)
},
onOfflineReady() {
console.log('App ready to work offline')
}
})
app.mount('#app')