auth-module icon indicating copy to clipboard operation
auth-module copied to clipboard

Test auth module with Nuxt 3

Open bmulholland opened this issue 3 years ago • 17 comments

make a new project with nuxt 3 and set up nuxt auth. https://v3.nuxtjs.org/

Then report back on if it works

bmulholland avatar Jan 20 '22 10:01 bmulholland

The Axios module is not yet compatible with Nuxt3, the first thing that happens when you start it is an axios error. They cant compiling it.

Intevel avatar Jan 22 '22 10:01 Intevel

Thanks for looking into it!

bmulholland avatar Jan 22 '22 14:01 bmulholland

Any update on it?

Lycoon avatar Feb 01 '22 14:02 Lycoon

No I don't think so, and as long as the Axios module is not compatible, the Auth module will not be compatible either.

Intevel avatar Feb 01 '22 14:02 Intevel

@Intevel i put a pull request for the axios module for nuxt 3, so waiting for that.

Denoder avatar Feb 03 '22 01:02 Denoder

@Intevel i put a pull request for the axios module for nuxt 3, so waiting for that.

Hello, is auth module working with ur pr? thank you for axios module yet auth module not working. Would you mind put a temporarily jwt auth project with your nuxt-module while waiting this project to work with nuxt3? T_T

ironytr avatar Feb 03 '22 22:02 ironytr

@Intevel i put a pull request for the axios module for nuxt 3, so waiting for that.

Hello, is auth module working with ur pr? thank you for axios module yet auth module not working. Would you mind put a temporarily jwt auth project with your nuxt-module while waiting this project to work with nuxt3? T_T

Unfortunately the auth module does not work with the PR as there's changes needed to be made to the auth module itself. Axios works with the pr but would need to do extra work with the auth module.

Denoder avatar Feb 04 '22 02:02 Denoder

Yes of course. But still, the Axios module has to work before we can work on the Auth Module for Nuxt 3. I will take a look at your PR. @Teranode

Intevel avatar Feb 04 '22 09:02 Intevel

Axios module works for me with {proxyHeaders: false}. It's just a little buggy.

kazigk avatar Feb 07 '22 21:02 kazigk

@kazigk What seems to be the issues you are having?

Denoder avatar Feb 08 '22 16:02 Denoder

currently have a nuxt-auth project which only works on my local machine, but when deployed on live server it doesn't work

tad0xe avatar Feb 12 '22 20:02 tad0xe

I made a module directory for nuxt-community plugins I utilize for nuxt 3. You can use these until the current modules are updated: https://github.com/Teranode/nuxt-module-alternatives

Denoder avatar Feb 16 '22 22:02 Denoder

I made a module directory for nuxt-community plugins I utilize for nuxt 3. You can use these until the current modules are

I am confused?!

nuxt-module-alternatives Alternative modules to use while waiting for Nuxt 3 Compatibility

Current Modules

Nuxt Axios Module: Nuxt Community Repository Nuxt Proxy Module: Nuxt Community Repository Nuxt Auth Module: Nuxt Community Repository Nuxt Google Fonts Module: Nuxt Community Repository VueJS/Nuxt Pinia: VueJS/Nuxt Pinia Repository Nuxt Element Plus: ? Nuxt Vuex: ?

The Nuxt Auth Module: Nuxt Community Repository links exactly to this repository, which does not work with Nuxt3

nyxb avatar Feb 19 '22 16:02 nyxb

@VidarDev

the links are references to the repositories of the modules im currently modifying. The @nuxtjs folder contains the auth module, look at the readme.

Denoder avatar Feb 19 '22 18:02 Denoder

@Teranode

nvm my bad >.< now i check it ^^ good job and thanks for that

nyxb avatar Feb 19 '22 18:02 nyxb

Was trying to use auth module with a fresh Nuxt 3 install:

[vite] Internal server error: Failed to resolve import "./middleware" from ".nuxt\auth.js". Does the file exist?
Plugin: vite:import-analysis

Vite does not love this line: https://github.com/nuxt-community/auth-module/blob/c9880dc28fa13ba036f078d37ff76e1267c65d21/templates/plugin.js#L1

droplister avatar Jun 09 '22 03:06 droplister

nuxt 3 uses $fetch, why not make autn on fetch???

pa3datka avatar Aug 27 '22 15:08 pa3datka

any update?

marwenbk avatar Sep 26 '22 05:09 marwenbk

Nuxt 3 support is coming as part of a broader re-write, and you can track that status at https://v3.nuxtjs.org/community/roadmap/#-core-modules

bmulholland avatar Sep 26 '22 08:09 bmulholland

Is there an estimated timeframe? It just says "planned". In the meantime, what is the suggestion to use either instead or as a workaround?

OblivionSY avatar Nov 07 '22 20:11 OblivionSY

Is this it?

https://www.npmjs.com/package/@nuxtjs-alt/auth

Arturexe avatar Dec 04 '22 19:12 Arturexe

Closing this issue, as the current module will not work with Nuxt 3. You can track the timeline for Nuxt 3 support at https://nuxt.com/docs/community/roadmap/#-core-modules. That's the latest information I have.

bmulholland avatar Dec 05 '22 12:12 bmulholland

This also seems a good alternative for Nuxt 3: https://sidebase.io/nuxt-auth/getting-started . It is based on a popular auth library for Next.js.

KoenCa avatar Jan 09 '23 15:01 KoenCa