andreasb
andreasb
Explore posts from servers
KKinde
Created by andreasb on 2/5/2024 in #💻┃support
Auth check in +layout.server.ts – known issues?
Hi! 🙌 From working in SvelteKit I've gotten used to avoiding +layout.server.ts for auth checks (reasons illustrated by Svelte connoisseur Hunter Johnston in [1] and [2]), but the Kinde docs uses +layout.server.ts as an example of auth checking [3]. Are there any particular implementation details in Kinde making the issues raised in [1] and [2] null and void? [1] https://www.youtube.com/watch?v=UbhhJWV3bmI [2] https://www.youtube.com/watch?v=K1Tya6ovVOI [3] https://kinde.com/docs/developer-tools/sveltekit-sdk/#check-if-the-user-is-authenticated
6 replies