-
Hey everyone, I would like to know if it is somehow possible to modify they array keys which react query is using for it's cache. For example: I would like to use the unique id from each object instead of a sequential number. Reason is that I'm using subscriptions to update the entries and I would like to update them by id instead to iterate through the whole array (which could contain thousands of entries in my project) every time. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
the structure of data in the query cache is determined by what your QueryFunction returns. React Query doesn't dictate a structure (except for InfiniteQueries) |
Beta Was this translation helpful? Give feedback.
the structure of data in the query cache is determined by what your QueryFunction returns. React Query doesn't dictate a structure (except for InfiniteQueries)