Denoder / nuxt-module-alternatives

Alternative modules to use while waiting for Nuxt 3 Compatibility
MIT License
144 stars 14 forks source link

auth+i18n infinite redirect #122

Closed mittci closed 2 years ago

mittci commented 2 years ago

Environment

nuxt 3 edge

Nuxt Config

https://github.com/Maxp777/nuxt3

Reproduction

https://github.com/Maxp777/nuxt3

Describe the bug

That not work now, but worked some time ago

import { defineNuxtPlugin } from '#app'

export default defineNuxtPlugin((nuxtApp) => {
  nuxtApp.$auth.onRedirect((to: any) => {
    console.log(nuxtApp.$localePath(to)) // <-----------------------it output infinite times
    return nuxtApp.$localePath(to)
  })
}) 

Additional context

With that work, or is need to return second parameter options as an object like in original module

https://github.com/Teranode/nuxt-module-alternatives/pulls

Logs

No response

Denoder commented 2 years ago

update your auth module.

stale[bot] commented 2 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.