usage of queryClient.getQueryData results in errors
Hello
Im using Nuxt3 (SPA) and have a query ta fetch data and then i have a function that retrieve that data into the cache (later stage it will apply some filterting/mapping). When i try to call that function to return the query cache, i get the following errors:
In console:
In IDE (Webstorm 2022.3.1)
The code:
Template
The useQuery works fine, however it's when trying to access the queryClient that things goes south on my side. I've tried looking into the discord but didn't find relevant errors with the typing error and the 'exact' key problem
I tried to add the ´{exact: false}´ filter to the getQueryData but still no chance
Do you see any wrong doing in what im trying to achieve ? If needed i can make a replica
Thanks in advance
Im using Nuxt3 (SPA) and have a query ta fetch data and then i have a function that retrieve that data into the cache (later stage it will apply some filterting/mapping). When i try to call that function to return the query cache, i get the following errors:
In console:
In IDE (Webstorm 2022.3.1)
TS2345: Argument of type 'string' is not assignable to parameter of type 'MaybeRefDeep '.const cachedData = queryClient.getQueryData('dealsPreviews')The code:
Template
The useQuery works fine, however it's when trying to access the queryClient that things goes south on my side. I've tried looking into the discord but didn't find relevant errors with the typing error and the 'exact' key problem
I tried to add the ´{exact: false}´ filter to the getQueryData but still no chance
Do you see any wrong doing in what im trying to achieve ? If needed i can make a replica
Thanks in advance
