Skip to content

Refresh stale data in CacheFirstInterceptor #186

@halberto-deezer

Description

@halberto-deezer

Could we have a parameter (At ApolloClient or Query level maybe ?) that allows the cache to be refreshed in case the data that was called is stale ?

I think only the CacheFirstInterceptor is expected to be changed.

Testing on my side with :

val shouldFetchNetwork = cacheResponse.cacheInfo?.isStale == true || cacheResponse.exception != null

in the fetch interceptor works.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions