I have a http request /api/speakers/
and I want it to be cached by browser.
So I added Cache-Control
to the request headers:
headers: {
'Cache-Control': 'public, must-revalidate, max-age=86400'
}
cache-control
appears in request headers, but every time it requests it gets new data from response. I am testing without refreshing page, so that is not the problem.
What am I doing wrong? How to tell browser to cache request responses and not to request it next one day.