-
I have created a simplified codesandbox to illustrate my problem here: https://codesandbox.io/s/pedantic-waterfall-90i2fk?file=/src/App.js In this example there are 3 'widgets'. Each widgets makes a dummy query using I can't seem to figure out why this is happening. In the query |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
quite simply, you are creating a
you can either:
both ways work equally well. |
Beta Was this translation helpful? Give feedback.
-
🤦♂️ Ah!! Didn't catch that one thank you |
Beta Was this translation helpful? Give feedback.
quite simply, you are creating a
new QueryClient
inside yourApp
on each render. The client holds the cache, so making a new one will throw it away:you can either:
both ways work equally well.