tanstack-query-setup
Installation
SKILL.md
TanStack Query Setup
Manage server state with powerful caching, background updates, and optimistic UI.
Core Workflow
- Install and configure: Set up QueryClient
- Create queries: Define data fetching hooks
- Add mutations: Handle data modifications
- Enable caching: Configure stale times
- Implement optimistic updates: Instant UI feedback
- Add infinite queries: Pagination and infinite scroll
Installation
npm install @tanstack/react-query @tanstack/react-query-devtools