OkCacheControl icon indicating copy to clipboard operation
OkCacheControl copied to clipboard

Controlling which url to cache?

Open AtherSajjad opened this issue 6 years ago • 1 comments

Hey @ncornette

This library is awesome without implementing cache in server we can cache the response. Is there any way to ignore the response caching for few urls which should always hit the network. Point me out in the right direction i can change and send you pull request for it.

Thanks,

AtherSajjad avatar Aug 23 '18 07:08 AtherSajjad

Hi @AtherSajjad

As mentioned in the doc, you can use Cache-Control: no-cache and Cache-Control: no-store headers on requests to obtain this result. This behaviour seems not to be verified by unittests, It would be great if you could add these tests to check it works, then I would be very happy to accept your pull request.

Cheers, Nicolas.

ncornette avatar Aug 23 '18 13:08 ncornette