TanStack Query Best Practices Expert patterns for TanStack Query in modern React applications with Next.js App Router and Server Components. NEVER Do With TanStack Query - NEVER use a singleton QueryClient on the server - Creates data leakage between users and race conditions. Each request must get its own isolated QueryClient instance to prevent cached data from one user appearing for another. - NEVER synchronize query data to useState - Background refetches, invalidations, and optimistic updates all modify the cache. Local state copies become stale immediately, causing "my save didn't work"…