fix: prevent session creation loop when running without backend
Make getOrCreateSession idempotent by returning the existing active session when called with no ID, instead of always creating a new one. Use untrack() in the $effect to sever SvelteMap dependency so it only re-runs on $page changes. Disable SSR on client-only routes, reduce preload aggressiveness, and skip retries when already disconnected. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2
src/routes/chat/+page.ts
Normal file
2
src/routes/chat/+page.ts
Normal file
@@ -0,0 +1,2 @@
|
||||
export const prerender = false;
|
||||
export const ssr = false;
|
||||
Reference in New Issue
Block a user