supabase / auth-helpers

A collection of framework specific Auth utilities for working with Supabase.

Home Page:https://supabase.github.io/auth-helpers/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Auth helpers for SvelteKit?

msdrigg opened this issue · comments

Any plans to get auth helpers together for sveltekit?

Yes, @silentworks is working on these 👍

Have you made any progress @silentworks

Any info on this?

This is currently working on the add-sveltekit branch, but I still need to create some helper functions and test it out in one of my real project. Hopefully there should be a version for everyone to play with by the end of next week.

Amazing thank you @silentworks - appreciate the heads up on branch access, I'll give it a spin tonight

@silentworks Is there anything you can use help with to get this show on the road?

Don't see any open issues relating to this, but I'd be glad to help in any way.

Hey @silentworks
Any estimates on this?

Looks like it's in the next branch now. Let me know if you want any help testing or writing docs @silentworks. It's looking great!

@brandtam It would be really awesome if you could help with testing this out and also writing the docs. I'm currently creating the documentation skeleton out and will post on here once I have it all in the repo then we can start filling out each section with content.

@silentworks I'm also testing it out. I'd be happy to help out with the docs @brandtam.
Also, quick question: I'm using the provider token to make some API calls to Spotify but it seems like it expires and isn't autorefreshing. I'm using the autoRefresh prop in the from '@supabase/auth-helpers-svelte'.

@pablodavila95 I think some code is missing around the provider_token side of the auth-helpers-svelte package. I will look into that this week and try to get a release out.

@silentworks is there a reason we have to add src/routes/api/auth/user.ts and src/routes/api/auth/callback.ts? It could all be done within handle.

Is the README.md conclusive? Or are there additional steps to take to get data fetching to work? I pasted the code from Client-side data fetching with RLS into an empty svelte file and followed all the other steps in the Read Me up to this section. I am using a magic link to authenticate. Only when I follow the magic link for the first time my RLS-protected data is on display. As soon as I refresh the page or follow the same link again $session.user has all the user data stored but loadedData is just an empty array. I'm learning SvelteKit and the authentication flow isn't easy for me to grasp. Is there an up-to-date example project for me to check out?

@silentworks is there a reason we have to add src/routes/api/auth/user.ts and src/routes/api/auth/callback.ts? It could all be done within handle.

@david-plugge That's something worth exploring, a PR for that would be welcomed too.

Is the README.md conclusive? Or are there additional steps to take to get data fetching to work? I pasted the code from Client-side data fetching with RLS into an empty svelte file and followed all the other steps in the Read Me up to this section. I am using a magic link to authenticate. Only when I follow the magic link for the first time my RLS-protected data is on display. As soon as I refresh the page or follow the same link again $session.user has all the user data stored but loadedData is just an empty array. I'm learning SvelteKit and the authentication flow isn't easy for me to grasp. Is there an up-to-date example project for me to check out?

@oliver-lehner please open a new issue for this and I will follow up there.

@silentworks i´ve created a PR #163

Thanks for that PR @david-plugge. I'm closing this issue now and think any further SvelteKit auth helper related issues should all be created as new issues on this repo.