You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello and thank you for this wonderful library, I have a question/suggestion...is it possible to set different cacheLife values for different responseIds? If not would it make sense to do something like that?
useGet("url-1", {
cacheLife: 60000
});
useGet("url-2", {
cacheLife: 1000
});
I appreciate your time, I was not seeing the ability to do that currently...it seemed like cacheLife would be "overwritten" for "url-1", to 1000 but I might be totally misunderstanding what is happening?
Here is an example where I am using useGet in 2 instances...in one I am setting a cacheLife of 60000ms to fetch a Kanye quote, in the other I am fetching a fake name to attribute the quote to and am setting the cacheLife to 1000ms....and it seems that both are using the 1000ms cacheLife:
Hello and thank you for this wonderful library, I have a question/suggestion...is it possible to set different cacheLife values for different responseIds? If not would it make sense to do something like that?
useGet("url-1", {
cacheLife: 60000
});
useGet("url-2", {
cacheLife: 1000
});
I appreciate your time, I was not seeing the ability to do that currently...it seemed like cacheLife would be "overwritten" for "url-1", to 1000 but I might be totally misunderstanding what is happening?
Here is an example where I am using useGet in 2 instances...in one I am setting a cacheLife of 60000ms to fetch a Kanye quote, in the other I am fetching a fake name to attribute the quote to and am setting the cacheLife to 1000ms....and it seems that both are using the 1000ms cacheLife:
https://codesandbox.io/p/sandbox/crazy-resonance-2nv6yn?file=%2Fsrc%2FApp.js
I appreciate any help/guidance on this...thanks!
The text was updated successfully, but these errors were encountered: