Denis Jankelaic
Denis Jankelaic
NNuxt
Created by Denis Jankelaic on 12/16/2024 in #❓・help
`non-preached-url` with `@vite-pwa/nuxt`
Hello, I get Uncaught (in promise) non-precached-url: non-precached-url :: [{"url":"/"}] error when visiting my homepage. My config is pretty basic:
pwa: {
registerType: 'autoUpdate',
workbox: {
navigateFallback: '/',
},
},
pwa: {
registerType: 'autoUpdate',
workbox: {
navigateFallback: '/',
},
},
How do I fix the error?
5 replies
NNuxt
Created by Denis Jankelaic on 11/19/2024 in #❓・help
Login with facebook through facebook mobile app.
So I have a working login with facebook through web already by redirecting user to https://www.facebook.com/v15.0/dialog/oauth. But I need a new functionality that if user is on mobile and has facebook app installed, it should try to open the app and let user authorize through it. How do I do it?
5 replies
NNuxt
Created by Denis Jankelaic on 7/30/2024 in #❓・help
Middlewares no longer work.
Since we upgraded from 3.11.2 to 3.12.4 middlewares are no longer loading up.
definePageMeta({
middleware: 'auth',
})
definePageMeta({
middleware: 'auth',
})
Is there a new way to implement this? file is middleware/auth.ts
import { Routes } from '~/enums/Routes'
import QueryEnum from '~/enums/QueryEnum'
import getLocalizedRoute from '~/utils/getLocalizedRoute'

export default defineNuxtRouteMiddleware(async (_to, from) => {
const loggedIn = await useCurrentUser().isLoggedIn()

if (!loggedIn) {
return navigateTo(
getLocalizedRoute(
Routes.Login,
{},
{
[QueryEnum.Redirect]: from.fullPath,
}
)
)
}
})
import { Routes } from '~/enums/Routes'
import QueryEnum from '~/enums/QueryEnum'
import getLocalizedRoute from '~/utils/getLocalizedRoute'

export default defineNuxtRouteMiddleware(async (_to, from) => {
const loggedIn = await useCurrentUser().isLoggedIn()

if (!loggedIn) {
return navigateTo(
getLocalizedRoute(
Routes.Login,
{},
{
[QueryEnum.Redirect]: from.fullPath,
}
)
)
}
})
4 replies
NNuxt
Created by Denis Jankelaic on 4/9/2024 in #❓・help
Partytown + Nuxt3
No description
2 replies
NNuxt
Created by Denis Jankelaic on 3/21/2024 in #❓・help
Memory leaks since 3.9.0 version.
No description
11 replies
NNuxt
Created by Denis Jankelaic on 3/20/2024 in #❓・help
⚠ Invalid regular expression: invalid group specifier name
No description
2 replies