Forum Stats

  • 3,873,041 Users
  • 2,266,499 Discussions
  • 7,911,412 Comments

Discussions

offline-persistence-toolkit is not honoring the max-age

SatishKumar11
SatishKumar11 Member Posts: 6 Green Ribbon

We are implementing the 'offline-persistence-toolkit' in our code with getCacheFirstStrategy for client side caching.

As i understand "Responses from REST services to your application must not include either the no-cache or no-store value in the Cache-Control HTTP header as these values prevent the toolkit from working in your application"

So accordingly our API's are not returning those headers. The caching part works fine.

But our expectation was the toolkit will honor the max-age header and if the data is stale it will browserFetch instead of fetching from cache. But that does not seem to happen. So , are we missing something here?

Tagged:

Answers