apollo icon indicating copy to clipboard operation
apollo copied to clipboard

fix: cache value false to rewrite default cache policy

Open Stanislavsonder opened this issue 1 year ago • 4 comments

Now cache: false is not affecting on the query policy. So, if the application has 'cache-first' and you need a query with disabled caching, it is not feasible to achieve. This small fix should allow to do it.

Stanislavsonder avatar Jun 17 '24 00:06 Stanislavsonder

I need this too, I was even thinking about allowing to set the fetchPolicy manually. But I don't know if there's a reason it was decided to turn it into a boolean.

Try adding reviewers that are able to merge this.

sneakylenny avatar Jun 20 '24 07:06 sneakylenny

Looks like I have no rights to add reviewers here :D All that I can do is ping folks and ask them to check. I am just wondering if this repo is still alive :D @Diizzayy @danielroe

@timyourivh As a workaround, you can try to use "5.0.0-alpha.11" for now, which does not apply changes. But to be honest this cache issue is not my biggest problem with this module :)

Stanislavsonder avatar Jun 20 '24 15:06 Stanislavsonder

Hi guys, we are also dealing with the issue, BUT i think even this PR is not enough. Please see bug ticket: https://github.com/nuxt-modules/apollo/issues/631

awacode21 avatar Aug 06 '24 22:08 awacode21

@awacode21 GOOD LUCK :D

Stanislavsonder avatar Aug 07 '24 02:08 Stanislavsonder

Old thread here but what have people done here - regarding a work around. Would love to help but just know enough to be dangerous :( and test.

jumptrnr avatar Mar 05 '25 12:03 jumptrnr

but what have people done here - regarding a work around.

I disabled cache all together, check my observation here: https://github.com/nuxt-modules/apollo/issues/496#issuecomment-2180717008

Later, due to overhead, we dropped GraphQL in favor of traditional REST API

sneakylenny avatar Mar 05 '25 15:03 sneakylenny

Later, due to overhead, we dropped GraphQL in favor of traditional REST API

The same for me. Unfortunately.

Stanislavsonder avatar Mar 05 '25 15:03 Stanislavsonder