tanstack-query

Official

Master async state, fetch data like a pro.

AuthorMadAppGang
Version1.0.0
Installs0

System Documentation

What problem does it solve?

Managing asynchronous server state, data fetching, caching, and synchronization in React applications can be complex and error-prone. This Skill provides battle-tested patterns for TanStack Query v5.

Core Features & Use Cases

  • Async State Management: Handle data fetching, caching, background updates, and synchronization automatically.
  • Optimistic Updates: Implement advanced optimistic UI with rollback for a smooth user experience.
  • Type-Safe API: Leverage queryOptions and TypeScript inference for robust and error-free data interactions.
  • Use Case: Implement a "create todo" feature with an optimistic update that instantly shows the new todo in the UI, then rolls back if the API call fails, all while ensuring cache consistency.

Quick Start

Use the tanstack-query skill to implement a useTodosQuery hook for fetching a list of todos.

Dependency Matrix

Required Modules

@tanstack/react-queryaxios

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: tanstack-query
Download link: https://github.com/MadAppGang/claude-code/archive/main.zip#tanstack-query

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository