tanstack-query

Installation
SKILL.md

TanStack Query

Use this skill when work touches TanStack Query v5, especially @tanstack/react-query, server-state caching, query/mutation lifecycle issues, SSR hydration, or migrations from React Query/TanStack Query v4.

Workflow

  1. Inspect the local Query shape before changing code:
    • Package versions for @tanstack/react-query, @tanstack/query-core, devtools, persist/broadcast packages, ESLint plugin, React, framework router, and test utilities.
    • Provider setup: QueryClient, QueryClientProvider, SSR request scoping, default options, devtools, and persistence providers.
    • Query conventions: query key factories, queryOptions, mutationOptions, custom hooks, router loaders, SSR prefetching, and invalidation helpers.
    • Runtime intent: client-only fetching, server prefetch and hydration, route preloading, offline/persistence, or multi-tab sync.
  2. Refresh docs for current behavior, package drift, SSR, persistence, or migrations. Start from source-map.md.
  3. For installation, provider setup, defaults, query keys, useQuery, and TypeScript options, use setup-core.md.
  4. For dependent, parallel, paginated, infinite, disabled, cancellable, selected, and performance-sensitive queries, use query-patterns.md.
  5. For useMutation, invalidation, direct cache writes, optimistic updates, mutation scopes, and offline mutations, use mutations-cache.md.
  6. For prefetching, router integration, SSR, hydration, Suspense, Server Components, and streaming caveats, use ssr-prefetching.md.
  7. For persistence, broadcast sync, devtools, ESLint, testing, and migration checks, use production-tooling.md.

Implementation Judgment

Installs
41
GitHub Stars
1
First Seen
Jul 10, 2026
tanstack-query — dobroslavradosavljevic/skills