T
TanStackβ€’4y ago
correct-apricot

No ReactQuery Dev Tools - NextJS Container

Hello TanStack Community! I am trying to integrate my love of ReactQuery in a new project NextJS monorepo governed by Docker. TLDR: NextJS container is running NODE_ENV=production due to build command therefore ReactQuery devtools are not shown despite this being a development build. ------ The current development flow builds all containers in one step (docker compose -f docker/development/docker-compose.yml build) and runs them in another (docker compose -f docker/development/docker-compose.yml up -d). However, because I need to run the NextJS build command it automatically puts the NODE_ENV in production and this cannot be overwritten. People are suggesting using other variables like APP_ENV that you would have control over as a custom env BUT our beloved ReactQuery relies on this variable to show the developer tools. THANK YOU FOR ANY SUGGESTIONS πŸ™‚
2 Replies
stormy-gold
stormy-goldβ€’4y ago
Devtools | TanStack Query Docs
Wave your hands in the air and shout hooray because React Query comes with dedicated devtools! Γ°ΕΈΒ₯Β³ When you begin your React Query journey, you'll want these devtools by your side. They help visualize all of the inner workings of React Query and will likely save you hours of debugging if you find yourself in a pinch!
stormy-gold
stormy-goldβ€’4y ago
you can also do this without the lazy import

Did you find this page helpful?