Sveltekit Subdomain Auth Cookies

Hello, can someone show me how to make cookies work under sveltekit ? i did followed the Better Auth Svelte Kit Integration tutorial with the env vars

ORIGIN=https://subdomain.domain.com
BETTER_AUTH_URL=https://subdomain.domain.com
BETTER_AUTH_SECRET=dsaduiasiuyduiui

when using magic link, first the response contains the cookie under name: __Secure-better-auth.session_token
and is stored in the browser cookies, but on next reload or load it disapears
Was this page helpful?