Something went wrong. Try again.
Retro Bulletin Board Systems on atproto. Web app and TUI.
lazy mirror of alyraffauf/atbbs atbbs.xyz
Something went wrong. Try again.
1234567891011121314151617181920212223import { createSyncStoragePersister } from "@tanstack/query-sync-storage-persister";import { version } from "../../package.json";
const BUSTER = version;const MAX_AGE = 24 * 60 * 60 * 1000;
const persister = createSyncStoragePersister({ storage: localStorage, key: "atbbs:query-cache",});
export const persistOptions = { persister, buster: BUSTER, maxAge: MAX_AGE, dehydrateOptions: { // thread-page keys are fingerprinted by reply rkeys, so persisting them // would accumulate stale entries. thread-refs drives page rebuild on load. shouldDehydrateQuery: (query: { queryKey: readonly unknown[] }) => query.queryKey[0] !== "thread-page", },};