Skip to content

Doesn't the browser respect Cache-Control headers by default? #655

Closed Answered by arthurfiorette
sdandois asked this question in Q&A
Discussion options

You must be logged in to vote

Hey @sdandois.

For non browser environments, cache is not done by default. So using a library is the only solution.

The problem with browser default cache-control implementation is that it behaves differently for each browser: Chromium/safari/etc. Also it just respects basic cache, which is what cache-control/etag/etc helps you with. If you backend does not returns these headers, if you need to cache in a different behavior than what the server says, or any possibility that is not what the server told you explicitly (most of the time it doesn't even send them) to do, a library is necessary. Using the same cache library everywhere, working for everyone seems a better alternative. However, …

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@sdandois
Comment options

@arthurfiorette
Comment options

Answer selected by sdandois
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants