Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting Started in Sveltekit is Not working #12719

Open
Silal123 opened this issue Feb 28, 2025 · 8 comments · May be fixed by #12751
Open

Getting Started in Sveltekit is Not working #12719

Silal123 opened this issue Feb 28, 2025 · 8 comments · May be fixed by #12751
Labels
triage Unseen or unconfirmed by a maintainer yet. Provide extra information in the meantime.

Comments

@Silal123
Copy link

What is the improvement or update you wish to see?

Hello, Yesterday i wanted to Work with the Sveltekit AuthJS lib but it Just wouldnt Work. I First used the https://authjs.dev/getting-started/authentication/credentials?framework=sveltekit guide but later i figured Out there is a Guide wich Looks better and i think that also works https://authjs.dev/reference/sveltekit

Is there any context that might help us understand?

I only wrote one of the Pages but i think all the Sveltekit docs schould be updated

Does the docs page already exist? Please link to it.

https://authjs.dev/getting-started/authentication/credentials?framework=sveltekit

@Silal123 Silal123 added the triage Unseen or unconfirmed by a maintainer yet. Provide extra information in the meantime. label Feb 28, 2025
@PierrickP
Copy link

https://github.com/nextauthjs/next-auth/releases/tag/%40auth%2Fsveltekit%401.8.0 probably introduced breaking changes (or bug).

I tried to upgrade on my base code but auth didn't worked as before.
I've rollbacked to the previous version

@sinomsinom
Copy link

https://github.com/nextauthjs/next-auth/releases/tag/%40auth%2Fsveltekit%401.8.0 probably introduced breaking changes (or bug).

I tried to upgrade on my base code but auth didn't worked as before. I've rollbacked to the previous version

This might be the reason for the breaking changes/bug:
#12249 (comment)

The endpoint that signin and signout call was changed, but the actual endpoint they need to call didn't change which broke things.

@jaysin586
Copy link

https://github.com/nextauthjs/next-auth/releases/tag/%40auth%2Fsveltekit%401.8.0 probably introduced breaking changes (or bug).
I tried to upgrade on my base code but auth didn't worked as before. I've rollbacked to the previous version

This might be the reason for the breaking changes/bug: #12249 (comment)

The endpoint that signin and signout call was changed, but the actual endpoint they need to call didn't change which broke things.

This is 100% spot on. I believe what they were attempting to do was bring in the baseURL config parameter. But instead brought in the base from $app/paths. Which is what the old code was doing. But I cannot be 100% sure. Patching it to use this instead does work though.

@WaciX
Copy link

WaciX commented Mar 4, 2025

I would imagine the base paths should be configurable with basePath and not the base path of the entire sveltekit application.
If base path is changed, then it should equally apply to everything, including default pages and callback urls. At the moment those remain unchanged. I can't find a way to make it work with this change. It's a regression, have to rollback to 1.7.4

@atuttle
Copy link

atuttle commented Mar 5, 2025

Chiming in as another affected person. Pinning to version 1.7.1 has allowed me to keep working, but I'm subscribing to get updates if/when this is resolved.

If anyone has any workarounds to use 1.8, please share specifics.

@edeleastar
Copy link

Same for me. Pinned to 1.7.4 to keep working. Using the client API.

@jaysin586
Copy link

I am pretty sure I can make the change. Give me a bit to get involved.

@debuggerpk
Copy link

rolling back to 1.7.4. subscribing.

@jaysin586 jaysin586 linked a pull request Mar 9, 2025 that will close this issue
3 tasks
hopperelec added a commit to hopperelec/competitive-replying that referenced this issue Mar 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triage Unseen or unconfirmed by a maintainer yet. Provide extra information in the meantime.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

8 participants