Skip to content

FR: http browser caching #45

Description

@MattiJarvinen

Htmlcache should set a few headers to enhance browser features.

If you have additional headers you'd like to see, please comment with a description, source/explanation/reason etc etc.

Headers:

  • cache-control: no-cache, no store or Cache-Control: private with max-age
  • expires?
  • etag
  • last-modified

Handle correctly:

  • if-none-match
  • if-modified-since

Sources:
https://jakearchibald.com/2016/caching-best-practices/
https://devcenter.heroku.com/articles/increasing-application-performance-with-http-cache-headers

Btw. is there a way to prevent headers & content being sent before onEndRequest? I was thinking if refreshing stale cache could be possible with etag & etc.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    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