In middleware.ts, you call the redirect function from auth.js. This function calls useRoute and results in a warning.
Additional context
No response
Logs
Calling useRoute within middleware may lead to misleading results. Instead, use the (to, from) arguments passed to the middleware to access the new and old routes.
Environment
Nuxt Config
// @ts-ignore export default defineNuxtConfig({ runtimeConfig: {},
modules: [ '@nuxt-alt/auth', '@nuxt-alt/http', '@nuxt-alt/proxy', ], })
Reproduction
I am absolutely sure that the issue is obvious.
Describe the bug
In middleware.ts, you call the redirect function from auth.js. This function calls useRoute and results in a warning.
Additional context
No response
Logs