Closed BoD closed 1 week ago
Can be used to know if data was received from the cache even though it was stale (can happen when using maxStale).
maxStale
To make this happen I had to change ApolloStore.readOperation() / readFragment() to allow it to return cache headers (breaking!).
ApolloStore.readOperation() / readFragment()
CacheResolver.resolveField() can now also return cache headers (not breaking because it returns Any?).
CacheResolver.resolveField()
Any?
In this PR also, rename ExpirationCacheResolver to CacheControlCacheResolver, and rename "Expiration" to "Cache control" in the documentation.
ExpirationCacheResolver
CacheControlCacheResolver
Fixes #51
Can be used to know if data was received from the cache even though it was stale (can happen when using
maxStale
).To make this happen I had to change
ApolloStore.readOperation() / readFragment()
to allow it to return cache headers (breaking!).CacheResolver.resolveField()
can now also return cache headers (not breaking because it returnsAny?
).In this PR also, rename
ExpirationCacheResolver
toCacheControlCacheResolver
, and rename "Expiration" to "Cache control" in the documentation.Fixes #51