Avis TanStack Query Integration
Capability: data fetching
Status: stable integration manifest, alpha project support
Supported ecosystems:
- Node
Supported frameworks:
- Next.js
Supported package managers:
- npm
- pnpm
- yarn
- bun
Package:
@tanstack/react-query
Command:
avis add tanstack-queryWhat Avis Does
Section titled “What Avis Does”- installs
@tanstack/react-querywhen it is not already present - creates a QueryClient provider module when it does not already exist
- verifies dependency and provider module presence
Files Avis May Create
Section titled “Files Avis May Create”For projects with an app directory:
src/app/providers.tsxorsrc/app/providers.jsxapp/providers.tsxorapp/providers.jsx
For projects without an app directory:
src/providers/query-provider.tsxorsrc/providers/query-provider.jsxproviders/query-provider.tsxorproviders/query-provider.jsx
Files Avis May Modify
Section titled “Files Avis May Modify”None.
Avis creates the provider module, but it currently does not patch your root layout to connect it.
Dependencies Added
Section titled “Dependencies Added”@tanstack/react-query
Verification
Section titled “Verification”avis doctor checks:
@tanstack/react-querydependency installed- provider module detected
If the dependency exists but the provider module is missing, Avis reports the integration as partially configured.
Idempotence
Section titled “Idempotence”Avis skips dependency installation when the package is already listed and skips provider creation when the expected provider file exists.
Manual Setup Differences
Section titled “Manual Setup Differences”Avis creates a small client component wrapping children in QueryClientProvider. You still need to import and mount it where appropriate for your Next.js app.