First reworks

This commit is contained in:
2024-10-28 17:49:46 +01:00
parent fef8c092a9
commit 1b2472bc1a
155 changed files with 536 additions and 4281 deletions

View File

@@ -1,7 +0,0 @@
export default defineNuxtPlugin(async (nuxtApp) => {
if (!nuxtApp.payload.serverRendered || Boolean(nuxtApp.payload.prerenderedAt) || Boolean(nuxtApp.payload.isCached)) {
nuxtApp.hook('app:mounted', async () => {
await useUserSession().fetch()
})
}
})

View File

@@ -1,11 +0,0 @@
export default defineNuxtPlugin({
name: 'session-fetch-plugin',
enforce: 'pre',
async setup(nuxtApp) {
// Flag if request is cached
nuxtApp.payload.isCached = Boolean(useRequestEvent()?.context.cache)
if (nuxtApp.payload.serverRendered && !nuxtApp.payload.prerenderedAt && !nuxtApp.payload.isCached) {
await useUserSession().fetch()
}
},
})

View File

@@ -1,5 +0,0 @@
import { GesturePlugin } from '@vueuse/gesture'
export default defineNuxtPlugin((nuxtApp) => {
nuxtApp.vueApp.use(GesturePlugin)
})