From 25d44a180ccff5bc2c12cc49cbd9dc45180e2463 Mon Sep 17 00:00:00 2001 From: Bryan Van Deusen Date: Thu, 23 Apr 2026 20:01:46 -0400 Subject: [PATCH] docs(plan): update Tasks 12/13 to unwrap TanStack Query's Readable store TanStack Query 5's Svelte adapter returns a Readable store, not a plain object. Pages need to destructure with $-subscription: const queryStore = $derived(createXQuery(id)); const query = $derived($queryStore); Applied to artist + album detail page templates. Task 11 already landed with this fix (and readable-wrapped mocks in test-utils). Co-Authored-By: Claude Opus 4.7 --- docs/superpowers/plans/2026-04-23-web-ui-library-views.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/docs/superpowers/plans/2026-04-23-web-ui-library-views.md b/docs/superpowers/plans/2026-04-23-web-ui-library-views.md index f66cb633..41f94383 100644 --- a/docs/superpowers/plans/2026-04-23-web-ui-library-views.md +++ b/docs/superpowers/plans/2026-04-23-web-ui-library-views.md @@ -1423,7 +1423,8 @@ Expected: FAIL — component not found. import type { ApiError } from '$lib/api/client'; const id = $derived(page.params.id); - const query = $derived(createArtistQuery(id)); + const queryStore = $derived(createArtistQuery(id)); + const query = $derived($queryStore); const showSkeleton = useDelayed(() => query.isPending); const notFound = $derived( @@ -1631,7 +1632,8 @@ Expected: FAIL — component not found. import type { ApiError } from '$lib/api/client'; const id = $derived(page.params.id); - const query = $derived(createAlbumQuery(id)); + const queryStore = $derived(createAlbumQuery(id)); + const query = $derived($queryStore); const showSkeleton = useDelayed(() => query.isPending); const notFound = $derived(