[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M78FM4FXBMBM3DBW5TGN9471":3,"skill-same:01M78FM4FXBMBM3DBW5TGN9471":53},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":6,"ownerHtmlUrl":29,"ownerBlogUrl":30,"ownerDescription":31,"updatedAt":32,"install":33,"resources":46},"01M78FM4FXBMBM3DBW5TGN9471","solid-offline-patterns",null,"Use when a Solid app flashes a loading screen on reopen, needs a durable WebID-scoped snapshot with background revalidation, leaks cached data across account switches, or must round-trip Date\u002FSet\u002FMap values safely. The package skill governs the solid-offline service-worker API; this skill supplies app caching patterns.","jeswr\u002Fsolid-sdk","jeswr","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F63333554?v=4","01M78F8AE112CQ0KHFC3R0Z8SJ","Jesse Wright","01M78F8AERJX4YWDA1S4BMF74V",2,"MIT","https:\u002F\u002Fgithub.com\u002Fjeswr\u002Fsolid-sdk\u002Fblob\u002Fmain\u002Fskills\u002Fsolid-offline-patterns\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: solid-offline-patterns\ndescription: Use when a Solid app flashes a loading screen on reopen, needs a durable WebID-scoped snapshot with background revalidation, leaks cached data across account switches, or must round-trip Date\u002FSet\u002FMap values safely. The package skill governs the solid-offline service-worker API; this skill supplies app caching patterns.\n---\n\n## Quick reference\n\nCached pod data is never authoritative: paint a matching WebID-scoped snapshot, then revalidate.\nPut the authenticated WebID in both cache key and envelope; clear on logout and account switch.\nUse explicit per-key codecs for durable snapshots; unregistered keys stay memory-only.\nUse the [package skill](..\u002F..\u002Fpackages\u002Fsolid-offline\u002FSKILL.md) for `createOfflineClient`, worker wiring, status hooks, and logout purge. Its API and security rules take precedence over this pattern guide.\n\n\u003C!-- AUTHORED-BY Codex GPT-6 -->\n\n\u003C!-- AUTHORED-BY Codex GPT-6.1-Sol -->\n\n\u003C!-- AUTHORED-BY Claude Opus 4.8 -->\n\n# Offline \u002F instant-load — stale-while-revalidate from a WebID-scoped cache\n\nRead the companion [`AGENTS.md`](..\u002F..\u002FAGENTS.md)\nfirst; this skill assumes that stack (`@solid\u002Freactive-authentication` patches `globalThis.fetch`,\nreads go through `@jeswr\u002Ffetch-rdf`, live-sync via the `solid-notifications` skill).\n\nA Solid app that re-reads every resource from the pod on each open shows a blank \"Loading…\"\nscreen for the round-trip — even when the data was already known a moment ago. The fix is\n**stale-while-revalidate**: on mount, hydrate the UI **synchronously** from a durable client cache\nso the app paints **instantly**, then fetch from the pod in the background and reconcile. Never\nshow a blank\u002Floading state when a cache exists. The **write** side of the same \"instant\" goal —\noptimistic, non-blocking mutations — is the\n[`solid-app-shell`](..\u002Fsolid-app-shell\u002FSKILL.md)\nskill.\n\nThis is an **app-level snapshot pattern** (`localStorage`\u002F`IndexedDB` render-shaped data).\nThe service-worker read-through cache now lives in [the workspace package](..\u002F..\u002Fpackages\u002Fsolid-offline\u002FREADME.md),\nwith `WebSocketChannel2023` invalidation (the `solid-notifications` skill).\nUntil that layer is wired into an app, hold the snapshot cache yourself as below.\nFor APIs, use [packages\u002Fsolid-offline\u002FSKILL.md](..\u002F..\u002Fpackages\u002Fsolid-offline\u002FSKILL.md);\nits current API and security guidance wins over the [historical availability note](references\u002Fsource-availability-note.md).\n\n## The pattern\n\n1. **Seed React state from the cache during the initial render** — not in an effect. A synchronous\n   cache (`localStorage`, or an in-memory mirror you populated earlier) lets you pass an initializer\n   to `useState` so the first paint already has data:\n   ```ts\n   const [snapshot, setSnapshot] = useState(() => hydrate(webId, resourceUrl));\n   ```\n   An effect runs *after* paint, so hydrating there reintroduces the blank flash. (`IndexedDB` is\n   async — for it, accept one async hydrate but still gate the loading state, below.)\n2. **Distinguish \"nothing yet\" from \"have cached\u002Floaded data\".** Keep an `initialLoading` flag that\n   is true **only** when you have neither a cache hydrate nor a completed fetch — so a\n   cache-hydrated view is never treated as \"loading\". A background revalidation must not flip the UI\n   back to a spinner.\n3. **Revalidate in the background and reconcile.** Fetch from the pod after mount (and on\n   live-sync), then replace the snapshot. Write the fresh result back to the cache so the next\n   reopen paints from it.\n4. **Guard against out-of-order fetches.** A slow older read (e.g. a live-sync refresh that started\n   before a mutation) must never clobber a newer result — gate writes behind a monotonic sequence\n   number (`++seq; … if (seq !== current) return;`).\n\n## Security — the cache MUST be scoped to the authenticated WebID\n\nThis is the load-bearing part, and the easy thing to get wrong. **A real HIGH was caught in\nreview**: an un-scoped cache let one signed-in user's private pod data paint for a *different* user\non the same browser (shared device, account switch, or just signing out and a colleague signing\nin) before authorization could revalidate. Issue data can differ per viewer (private resources,\nper-agent ACLs), so a snapshot one identity cached must **never** be shown to another.\n\nThe scoping rule has four parts — apply **all** of them:\n\n- **Put the WebID in BOTH the storage key AND the stored envelope.** The key keeps two users from\n  sharing a slot; the in-envelope WebID is checked on read as defence-in-depth (a key collision or\n  a copied entry can't leak). Use a separator that cannot appear in a URL (e.g. a NUL byte) so a\n  crafted WebID\u002Fresource can't forge another pair's key:\n  ```ts\n  const keyFor = (webId: string, resourceUrl: string) => `${PREFIX}${webId}\\u0000${resourceUrl}`;\n  ```\n- **Hydrate ONLY when the envelope's WebID matches the current authenticated identity.** A missing\n  WebID (not signed in yet) or a mismatch is a cache **MISS** — never a hydrate, never a \"show it\n  while we check\". Read the WebID from your authenticated session, not from the cache.\n- **Clear the cache on account switch AS WELL AS logout.** Logout-only clearing leaves the previous\n  user's snapshots on a switched device. Clear everything on both transitions.\n- **VERSION the envelope.** Bump a schema version on any shape change — including the moment you\n  *introduce* WebID scoping — so legacy un-scoped entries become unreadable and cannot be\n  resurrected. A version mismatch is a MISS.\n\n```ts\ninterface CacheEnvelope {\n  v: number;          \u002F\u002F schema version — bump to invalidate all entries (incl. legacy un-scoped)\n  at: number;         \u002F\u002F epoch ms — for a max-age bound on first-paint freshness\n  webId: string;      \u002F\u002F the identity that fetched this — only this WebID may paint it\n  resource: string;   \u002F\u002F the resource it belongs to — defence-in-depth vs key collisions\n  data: unknown;      \u002F\u002F render-shaped snapshot\n}\n\n\u002F\u002F MISS on: no storage, no resource, no authenticated WebID, version mismatch,\n\u002F\u002F WebID mismatch, resource mismatch, too old, or unparseable.\nfunction read(webId: string | null, resourceUrl: string, now = Date.now()): unknown | null {\n  if (!webId || !resourceUrl) return null;           \u002F\u002F no identity ⇒ never hydrate\n  try {\n    \u002F\u002F The getter itself can throw (e.g. SecurityError); acquire storage here too.\n    const storage = globalThis.localStorage;\n    if (!storage) return null;\n    const raw = storage.getItem(keyFor(webId, resourceUrl));\n    if (!raw) return null;\n    const env = JSON.parse(raw) as CacheEnvelope;\n    if (env.v !== VERSION || env.webId !== webId || env.resource !== resourceUrl) return null;\n    if (now - env.at > MAX_AGE_MS) return null;       \u002F\u002F bound first-paint staleness; still revalidates\n    return env.data;\n  } catch {\n    return null;                                       \u002F\u002F unavailable storage or corrupt data never blocks rendering\n  }\n}\n```\n\nMirror the same WebID scoping in the **live in-memory layer**, not just the durable cache: tag the\nin-memory snapshot with the WebID that fetched it, and derive the rendered view only when BOTH the\nresource AND the WebID match the active identity — so a view fetched by a previous user is neither\nrendered nor preserved when the identity changes (even if the resource URL is unchanged), no matter\nwhen a slow fetch lands.\n\n## Best-effort, never load-bearing\n\nThe cache is an optimisation. Any read\u002Fparse\u002Fquota error must degrade to \"no cache\" (a normal\nnetwork fetch), never throw and block the app. Swallow `localStorage` quota errors on write; treat\na corrupt entry as a MISS. The pod remains the source of truth — the cache only changes *when* the\nuser first sees data, never *what* is authoritative.\n\n`localStorage` is synchronous and size-capped: fine for small render snapshots (a list of\nrecords), and its synchronous read is exactly what enables the first-paint hydrate. A larger\npayload moves to `IndexedDB` at the cost of an async hydrate (then gate `initialLoading` until that\nhydrate settles, rather than seeding state synchronously).\n\n## In-memory cache ≠ cold open — and the value must round-trip\n\nTwo distinct layers, often conflated:\n\n- An **in-memory** stale-while-revalidate cache (e.g. an SWR map) survives *in-tab navigation* (home→away→home serves cached, no refetch) — but it is **lost on a full page reload**, so it does **nothing** for the cold-open loading screen. If a view bypasses the in-memory cache entirely (a raw `useEffect`+`fetch` per mount), it refetches even on in-tab navigation.\n- The **durable** snapshot (this skill) is what kills the *cold-open* spinner: persisted, WebID-scoped, hydrated **synchronously** on mount. You usually want both — route every cached read through the in-memory layer, and mirror it to durable.\n\n**Serialization must round-trip — guard the durable boundary with codecs.** A durable cache that does blanket `JSON.stringify`\u002F`JSON.parse` of a generic `T` silently corrupts any value that isn't JSON-plain: a `Date` hydrates back as a **string**, a `Set`\u002F`Map`\u002F`URL`\u002Fclass instance loses its type — while TypeScript still hands it back typed as `T`, so cold-open rendering breaks or shows wrong data with no error. Make durable persistence **opt-in per cache key with an explicit codec** (`encode → JsonValue`, `decode → T`): a key with **no registered codec is memory-only** (the safe default — it can never silently persist a non-round-trippable shape), and a model with `Date` fields registers a codec that revives them. **Field-scope the reviver — never a generic \"revive every ISO-looking string\" walker.** A user-controlled string field can legitimately *be* an ISO-date string (a task titled `\"2026-01-01\"`); a blanket deep reviver turns it into a `Date`, and the next `title.trim()` throws on cold hydration. Revive only the **known** date fields (`created`, `endedAt`, …) by path, leaving every other field its parsed type. Test the round-trip through the **real** persisted path (an actual\u002Fin-memory `Storage`), not a fake double — a fake bypasses exactly the serialization boundary that bites — and assert a date-shaped *title* stays a string.\n\n## Gotchas\n\n| Gotcha | Detail |\n|---|---|\n| Blank flash returns | Hydrating in a `useEffect` paints empty first — seed `useState` with an initializer (sync cache) instead |\n| In-memory cache \"fixes\" nothing on reload | In-memory survives navigation, NOT cold open — add a durable snapshot for first-paint; route raw-fetch views through the cache so navigation stops refetching |\n| `Date`\u002F`Set`\u002F`Map` hydrate as the wrong type | Blanket `JSON.parse` of generic `T` drifts types silently — opt-in per-key codecs; unregistered key = memory-only; test the real Storage round-trip |\n| Generic date-reviver crashes on a date-shaped title | A deep \"revive every ISO string\" reviver turns a user `title`\u002F`description` that looks like a date into a `Date` → `title.trim()` throws — field-scope the reviver to KNOWN date paths only |\n| `.ts` test file committed as binary | Tests for WebID-scoped keys often embed the `\\u0000` separator as a **literal NUL** → git treats the file as binary (unreviewable, breaks tooling) — write it as the escape `\"\\u0000\"`, not a raw NUL byte |\n| One user's data shown to another | The HIGH this skill exists for — WebID in key **and** envelope, hydrate only on identity match, clear on switch+logout, version the envelope |\n| Stale data after logout on a shared device | Logout-only clearing isn't enough — clear on **account switch** too |\n| Legacy entries resurrect after a shape change | Un-versioned envelopes — bump `VERSION` (including when you introduce WebID scoping) so old entries are a MISS |\n| Slow refresh clobbers newer data | Background\u002Flive-sync fetches race — gate the apply behind a monotonic fetch sequence |\n| Spinner during background revalidation | `loading` conflated with `initialLoading` — `initialLoading` is true only with no cache **and** no completed fetch |\n\n---\n\n*Learned building [`jeswr\u002Fsolid-issues`](..\u002F..\u002Fapps\u002Fissues\u002FREADME.md): the WebID-scoped\ndurable cache in [`src\u002Flib\u002Fissue-cache.ts`](..\u002F..\u002Fapps\u002Fissues\u002Fsrc\u002Flib\u002Fissue-cache.ts)\n(`readIssueCache`\u002F`writeIssueCache`\u002F`clearAllIssueCaches`, versioned `CacheEnvelope`) and the\nWebID-scoped in-memory snapshot in [`src\u002Flib\u002Fuse-issues.ts`](..\u002F..\u002Fapps\u002Fissues\u002Fsrc\u002Flib\u002Fuse-issues.ts)\n(`hydrate`, the `TrackerSnapshot` tagged with `creator`), commit `ca0c687`. The cross-user-leak HIGH\nwas a roborev finding fixed in that change.*\n","## Quick reference\n\nCached pod data is never authoritative: paint a matching WebID-scoped snapshot, then revalidate.\nPut the authenticated WebID in both cache key and envelope; clear on logout and account switch.\nUse explicit per-key codecs for durable snapshots; unregistered keys stay memory-only.\nUse the [package skill](..\u002F..\u002Fpackages\u002Fsolid-offline\u002FSKILL.md) for `createOfflineClient`, worker wiring, status hooks, and logout purge. Its API and security rules take precedence over this pattern guide.\n\n\u003C!-- AUTHORED-BY Codex GPT-6 -->\n\n\u003C!-- AUTHORED-BY Codex GPT-6.1-Sol -->\n\n\u003C!-- AUTHORED-BY Claude Opus 4.8 -->\n\n# Offline \u002F instant-load — stale-while-revalidate from a WebID-scoped cache\n\nRead the companion [`AGENTS.md`](..\u002F..\u002FAGENTS.md)\nfirst; this skill assumes that stack (`@solid\u002Freactive-authentication` patches `globalThis.fetch`,\nreads go through `@jeswr\u002Ffetch-rdf`, live-sync via the `solid-notifications` skill).\n\nA Solid app that re-reads every resource from the pod on each open shows a blank \"Loading…\"\nscreen for the round-trip — even when the data was already known a moment ago. The fix is\n**stale-while-revalidate**: on mount, hydrate the UI **synchronously** from a durable client cache\nso the app paints **instantly**, then fetch from the pod in the background and reconcile. Never\nshow a blank\u002Floading state when a cache exists. The **write** side of the same \"instant\" goal —\noptimistic, non-blocking mutations — is the\n[`solid-app-shell`](..\u002Fsolid-app-shell\u002FSKILL.md)\nskill.\n\nThis is an **app-level snapshot pattern** (`localStorage`\u002F`IndexedDB` render-shaped data).\nThe service-worker read-through cache now lives in [the workspace package](..\u002F..\u002Fpackages\u002Fsolid-offline\u002FREADME.md),\nwith `WebSocketChannel2023` invalidation (the `solid-notifications` skill).\nUntil that layer is wired into an app, hold the snapshot cache yourself as below.\nFor APIs, use [packages\u002Fsolid-offline\u002FSKILL.md](..\u002F..\u002Fpackages\u002Fsolid-offline\u002FSKILL.md);\nits current API and security guidance wins over the [historical availability note](references\u002Fsource-availability-note.md).\n\n## The pattern\n\n1. **Seed React state from the cache during the initial render** — not in an effect. A synchronous\n   cache (`localStorage`, or an in-memory mirror you populated earlier) lets you pass an initializer\n   to `useState` so the first paint already has data:\n   ```ts\n   const [snapshot, setSnapshot] = useState(() => hydrate(webId, resourceUrl));\n   ```\n   An effect runs *after* paint, so hydrating there reintroduces the blank flash. (`IndexedDB` is\n   async — for it, accept one async hydrate but still gate the loading state, below.)\n2. **Distinguish \"nothing yet\" from \"have cached\u002Floaded data\".** Keep an `initialLoading` flag that\n   is true **only** when you have neither a cache hydrate nor a completed fetch — so a\n   cache-hydrated view is never treated as \"loading\". A background revalidation must not flip the UI\n   back to a spinner.\n3. **Revalidate in the background and reconcile.** Fetch from the pod after mount (and on\n   live-sync), then replace the snapshot. Write the fresh result back to the cache so the next\n   reopen paints from it.\n4. **Guard against out-of-order fetches.** A slow older read (e.g. a live-sync refresh that started\n   before a mutation) must never clobber a newer result — gate writes behind a monotonic sequence\n   number (`++seq; … if (seq !== current) return;`).\n\n## Security — the cache MUST be scoped to the authenticated WebID\n\nThis is the load-bearing part, and the easy thing to get wrong. **A real HIGH was caught in\nreview**: an un-scoped cache let one signed-in user's private pod data paint for a *different* user\non the same browser (shared device, account switch, or just signing out and a colleague signing\nin) before authorization could revalidate. Issue data can differ per viewer (private resources,\nper-agent ACLs), so a snapshot one identity cached must **never** be shown to another.\n\nThe scoping rule has four parts — apply **all** of them:\n\n- **Put the WebID in BOTH the storage key AND the stored envelope.** The key keeps two users from\n  sharing a slot; the in-envelope WebID is checked on read as defence-in-depth (a key collision or\n  a copied entry can't leak). Use a separator that cannot appear in a URL (e.g. a NUL byte) so a\n  crafted WebID\u002Fresource can't forge another pair's key:\n  ```ts\n  const keyFor = (webId: string, resourceUrl: string) => `${PREFIX}${webId}\\u0000${resourceUrl}`;\n  ```\n- **Hydrate ONLY when the envelope's WebID matches the current authenticated identity.** A missing\n  WebID (not signed in yet) or a mismatch is a cache **MISS** — never a hydrate, never a \"show it\n  while we check\". Read the WebID from your authenticated session, not from the cache.\n- **Clear the cache on account switch AS WELL AS logout.** Logout-only clearing leaves the previous\n  user's snapshots on a switched device. Clear everything on both transitions.\n- **VERSION the envelope.** Bump a schema version on any shape change — including the moment you\n  *introduce* WebID scoping — so legacy un-scoped entries become unreadable and cannot be\n  resurrected. A version mismatch is a MISS.\n\n```ts\ninterface CacheEnvelope {\n  v: number;          \u002F\u002F schema version — bump to invalidate all entries (incl. legacy un-scoped)\n  at: number;         \u002F\u002F epoch ms — for a max-age bound on first-paint freshness\n  webId: string;      \u002F\u002F the identity that fetched this — only this WebID may paint it\n  resource: string;   \u002F\u002F the resource it belongs to — defence-in-depth vs key collisions\n  data: unknown;      \u002F\u002F render-shaped snapshot\n}\n\n\u002F\u002F MISS on: no storage, no resource, no authenticated WebID, version mismatch,\n\u002F\u002F WebID mismatch, resource mismatch, too old, or unparseable.\nfunction read(webId: string | null, resourceUrl: string, now = Date.now()): unknown | null {\n  if (!webId || !resourceUrl) return null;           \u002F\u002F no identity ⇒ never hydrate\n  try {\n    \u002F\u002F The getter itself can throw (e.g. SecurityError); acquire storage here too.\n    const storage = globalThis.localStorage;\n    if (!storage) return null;\n    const raw = storage.getItem(keyFor(webId, resourceUrl));\n    if (!raw) return null;\n    const env = JSON.parse(raw) as CacheEnvelope;\n    if (env.v !== VERSION || env.webId !== webId || env.resource !== resourceUrl) return null;\n    if (now - env.at > MAX_AGE_MS) return null;       \u002F\u002F bound first-paint staleness; still revalidates\n    return env.data;\n  } catch {\n    return null;                                       \u002F\u002F unavailable storage or corrupt data never blocks rendering\n  }\n}\n```\n\nMirror the same WebID scoping in the **live in-memory layer**, not just the durable cache: tag the\nin-memory snapshot with the WebID that fetched it, and derive the rendered view only when BOTH the\nresource AND the WebID match the active identity — so a view fetched by a previous user is neither\nrendered nor preserved when the identity changes (even if the resource URL is unchanged), no matter\nwhen a slow fetch lands.\n\n## Best-effort, never load-bearing\n\nThe cache is an optimisation. Any read\u002Fparse\u002Fquota error must degrade to \"no cache\" (a normal\nnetwork fetch), never throw and block the app. Swallow `localStorage` quota errors on write; treat\na corrupt entry as a MISS. The pod remains the source of truth — the cache only changes *when* the\nuser first sees data, never *what* is authoritative.\n\n`localStorage` is synchronous and size-capped: fine for small render snapshots (a list of\nrecords), and its synchronous read is exactly what enables the first-paint hydrate. A larger\npayload moves to `IndexedDB` at the cost of an async hydrate (then gate `initialLoading` until that\nhydrate settles, rather than seeding state synchronously).\n\n## In-memory cache ≠ cold open — and the value must round-trip\n\nTwo distinct layers, often conflated:\n\n- An **in-memory** stale-while-revalidate cache (e.g. an SWR map) survives *in-tab navigation* (home→away→home serves cached, no refetch) — but it is **lost on a full page reload**, so it does **nothing** for the cold-open loading screen. If a view bypasses the in-memory cache entirely (a raw `useEffect`+`fetch` per mount), it refetches even on in-tab navigation.\n- The **durable** snapshot (this skill) is what kills the *cold-open* spinner: persisted, WebID-scoped, hydrated **synchronously** on mount. You usually want both — route every cached read through the in-memory layer, and mirror it to durable.\n\n**Serialization must round-trip — guard the durable boundary with codecs.** A durable cache that does blanket `JSON.stringify`\u002F`JSON.parse` of a generic `T` silently corrupts any value that isn't JSON-plain: a `Date` hydrates back as a **string**, a `Set`\u002F`Map`\u002F`URL`\u002Fclass instance loses its type — while TypeScript still hands it back typed as `T`, so cold-open rendering breaks or shows wrong data with no error. Make durable persistence **opt-in per cache key with an explicit codec** (`encode → JsonValue`, `decode → T`): a key with **no registered codec is memory-only** (the safe default — it can never silently persist a non-round-trippable shape), and a model with `Date` fields registers a codec that revives them. **Field-scope the reviver — never a generic \"revive every ISO-looking string\" walker.** A user-controlled string field can legitimately *be* an ISO-date string (a task titled `\"2026-01-01\"`); a blanket deep reviver turns it into a `Date`, and the next `title.trim()` throws on cold hydration. Revive only the **known** date fields (`created`, `endedAt`, …) by path, leaving every other field its parsed type. Test the round-trip through the **real** persisted path (an actual\u002Fin-memory `Storage`), not a fake double — a fake bypasses exactly the serialization boundary that bites — and assert a date-shaped *title* stays a string.\n\n## Gotchas\n\n| Gotcha | Detail |\n|---|---|\n| Blank flash returns | Hydrating in a `useEffect` paints empty first — seed `useState` with an initializer (sync cache) instead |\n| In-memory cache \"fixes\" nothing on reload | In-memory survives navigation, NOT cold open — add a durable snapshot for first-paint; route raw-fetch views through the cache so navigation stops refetching |\n| `Date`\u002F`Set`\u002F`Map` hydrate as the wrong type | Blanket `JSON.parse` of generic `T` drifts types silently — opt-in per-key codecs; unregistered key = memory-only; test the real Storage round-trip |\n| Generic date-reviver crashes on a date-shaped title | A deep \"revive every ISO string\" reviver turns a user `title`\u002F`description` that looks like a date into a `Date` → `title.trim()` throws — field-scope the reviver to KNOWN date paths only |\n| `.ts` test file committed as binary | Tests for WebID-scoped keys often embed the `\\u0000` separator as a **literal NUL** → git treats the file as binary (unreviewable, breaks tooling) — write it as the escape `\"\\u0000\"`, not a raw NUL byte |\n| One user's data shown to another | The HIGH this skill exists for — WebID in key **and** envelope, hydrate only on identity match, clear on switch+logout, version the envelope |\n| Stale data after logout on a shared device | Logout-only clearing isn't enough — clear on **account switch** too |\n| Legacy entries resurrect after a shape change | Un-versioned envelopes — bump `VERSION` (including when you introduce WebID scoping) so old entries are a MISS |\n| Slow refresh clobbers newer data | Background\u002Flive-sync fetches race — gate the apply behind a monotonic fetch sequence |\n| Spinner during background revalidation | `loading` conflated with `initialLoading` — `initialLoading` is true only with no cache **and** no completed fetch |\n\n---\n\n*Learned building [`jeswr\u002Fsolid-issues`](..\u002F..\u002Fapps\u002Fissues\u002FREADME.md): the WebID-scoped\ndurable cache in [`src\u002Flib\u002Fissue-cache.ts`](..\u002F..\u002Fapps\u002Fissues\u002Fsrc\u002Flib\u002Fissue-cache.ts)\n(`readIssueCache`\u002F`writeIssueCache`\u002F`clearAllIssueCaches`, versioned `CacheEnvelope`) and the\nWebID-scoped in-memory snapshot in [`src\u002Flib\u002Fuse-issues.ts`](..\u002F..\u002Fapps\u002Fissues\u002Fsrc\u002Flib\u002Fuse-issues.ts)\n(`hydrate`, the `TrackerSnapshot` tagged with `creator`), commit `ca0c687`. The cross-user-leak HIGH\nwas a roborev finding fixed in that change.*\n",{"name":5,"description":7},"main","5482abfe2666cc12f835fe360e8fad1f1e1dea8c","skills\u002Fsolid-offline-patterns",0,"https:\u002F\u002Fgithub.com\u002Fjeswr\u002Fsolid-sdk","https:\u002F\u002Fgithub.com\u002Fjeswr","jeswr.org\u002F#me","@solid Lead @theodi | PhD Candidate @OxfordHCC\r\n\r\n","2026-11-15 05:20:24",{"source":8,"skillName":5,"commands":34,"prompt":44,"zipAvailable":45},[35,38,41],{"tool":36,"command":37},"npx","npx skills add jeswr\u002Fsolid-sdk --skill solid-offline-patterns",{"tool":39,"command":40},"bunx","bunx skills add jeswr\u002Fsolid-sdk --skill solid-offline-patterns",{"tool":42,"command":43},"pnpm","pnpm dlx skills add jeswr\u002Fsolid-sdk --skill solid-offline-patterns","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fjeswr\u002Fsolid-sdk\u002Fblob\u002Fmain\u002Fskills\u002Fsolid-offline-patterns\u002FSKILL.md",true,[47],{"path":48,"resourceType":49,"resourceTypeDesc":50,"sizeBytes":51,"sourceHtmlUrl":52},"references\u002Fsource-availability-note.md","REFERENCE","参考文档",1007,"https:\u002F\u002Fgithub.com\u002Fjeswr\u002Fsolid-sdk\u002Fblob\u002Fmain\u002Fskills\u002Fsolid-offline-patterns\u002Freferences\u002Fsource-availability-note.md",[54,61,68,75,82,89],{"skillNo":55,"name":56,"nameZh":6,"description":57,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":58,"categories":59,"keywords":60,"publishedAt":19},"01M78FNRF6EV6SKPEYRZ6JTTQ3","storage-conformance","Work on @jeswr\u002Fstorage-conformance, the shared storage conformance suite package in the Solid SDK workspace.","https:\u002F\u002Fgithub.com\u002Fjeswr\u002Fsolid-sdk\u002Fblob\u002Fmain\u002Ftools\u002Fstorage-conformance\u002FSKILL.md",[],[],{"skillNo":62,"name":63,"nameZh":6,"description":64,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":65,"categories":66,"keywords":67,"publishedAt":19},"01M78FNMS7HQGD9EE43WAFEW6A","fetch-rdf-engine-tests","Maintain fetch-rdf's real Node WASM parser integration tests without introducing a reverse engine dependency in fetch-rdf.","https:\u002F\u002Fgithub.com\u002Fjeswr\u002Fsolid-sdk\u002Fblob\u002Fmain\u002Ftools\u002Ffetch-rdf-engine-tests\u002FSKILL.md",[],[],{"skillNo":69,"name":70,"nameZh":6,"description":71,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":72,"categories":73,"keywords":74,"publishedAt":19},"01M78FNK5M6ASAR3909JT6BZV1","alpha","Use when checking fixtures, including folded YAML descriptions.","https:\u002F\u002Fgithub.com\u002Fjeswr\u002Fsolid-sdk\u002Fblob\u002Fmain\u002Ftest\u002Ffixtures\u002Fcheck-skills\u002Fvalid\u002Fskills\u002Falpha\u002FSKILL.md",[],[],{"skillNo":76,"name":77,"nameZh":6,"description":78,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":19},"01M78FNGATR8F4N09HWSFVWBAF","widget","Use when testing package skills: YAML quoting works.","https:\u002F\u002Fgithub.com\u002Fjeswr\u002Fsolid-sdk\u002Fblob\u002Fmain\u002Ftest\u002Ffixtures\u002Fcheck-skills\u002Fvalid\u002Fpackages\u002Fwidget\u002FSKILL.md",[],[],{"skillNo":83,"name":84,"nameZh":6,"description":85,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":88,"publishedAt":19},"01M78FN9M05GCHYTK848SSMN9R","web-seo","Use when improving technical and entity SEO for a modern personal, portfolio, documentation, or marketing site, including crawlable HTML, canonical metadata, sitemap and robots, Person\u002FProfilePage JSON-LD, Core Web Vitals, and honest ranking expectations.","https:\u002F\u002Fgithub.com\u002Fjeswr\u002Fsolid-sdk\u002Fblob\u002Fmain\u002Fskills\u002Fweb-seo\u002FSKILL.md",[],[],{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":19},"01M78FN5ANETMSPMEFACSJ7JMC","solid-wac","Use when implementing or auditing Solid server WAC authorization, ACL creation and inheritance, auxiliary-resource escalation, method-to-mode mapping, 401 versus 403 challenges, WAC-Allow, or defensive typed ACL parsing with @solid\u002Fobject and @rdfjs\u002Fwrapper.","https:\u002F\u002Fgithub.com\u002Fjeswr\u002Fsolid-sdk\u002Fblob\u002Fmain\u002Fskills\u002Fsolid-wac\u002FSKILL.md",[],[]]