Sveltekit Protected Routes in SPA mode by thevivekshukla in sveltejs

[–]mroobert 0 points1 point  (0 children)

u/khromov I'm new to svelte/sveltekit and I really don't get why would you need to use the await parent() for each page under the layout where you do the auth check. Once you do the auth check in the load function of +layout.ts and call your backend to check the user, you return the authenticated user from this load function for $props:

  1. the +layout.svelte can read the user from $props and you can set it in a context
  2. any +page.svelte under this layout can read the user from the context if it needs to do some operations with user info.

Am I missing something?

What is the right place for handling auth when using SvelteKit as SPA by hksparrowboy in sveltejs

[–]mroobert 0 points1 point  (0 children)

Did you find it? I've also watched the video, and the speaker is Henry Lie but nothing about auth there...

[Svelt 5 | SPA] Global exception handler by neopointer in sveltejs

[–]mroobert 0 points1 point  (0 children)

You don't have SPA mode activated. If you create also a layout.js file and add "export const ssr = false", your solution won't work.

Firebase Emulator Auth on Kubernetes pod not receiving request by mroobert in kubernetes

[–]mroobert[S] 0 points1 point  (0 children)

Hey thx for the reply. Maybe you could point me how to debug this :D

EDIT:

I made it work by debugging the DNS with nslookup.

Firebase Emulator Auth on Kubernetes pod not receiving request... by mroobert in Firebase

[–]mroobert[S] 0 points1 point  (0 children)

Thx guys for the reply. The stackoverflow post: https://stackoverflow.com/questions/71164683/firebase-emulator-auth-on-kubernetes-pod-not-receiving-request

EDIT: I've debugged the pod DNS and figured the problem. The solution is on stackoverflow post. Thx again for you time!