Skip to content
This repository was archived by the owner on Dec 1, 2017. It is now read-only.
This repository was archived by the owner on Dec 1, 2017. It is now read-only.

relative URLs in cachified CSS files #37

@pirxpilot

Description

@pirxpilot

I have several resources (images) referenced from CSS file that is cachified - which means that they get 'cachify' treatment by the virtue of their URLs having the same prefix as the CSS file that is referencing them. It worked OK until #32 was merged - I know that images do not change whenever CSS changes (or vice versa) but it was a good enough solution.

Of course it does not work in 0.0.14 or later since we are now making sure that file we are returning has the same hash that is referenced by the URL.

If that really is a desired behavior, that's fine. If not I have couple of ideas I would gladly implement if there is any interest:

  1. we could make 'strict checking' optional, or
  2. we could make 'strict checking' smarter - for example by only allowing only a set of prefixes that we previously generated (which incidentally should be much faster than recalculating the hash on each request and still provide decent security)

If something like that seems remotely merge-able I'll try to prepare a PR. If I am missing the point here or misusing the module I'll close the issue to take my worries to a private fork.
Thanks for the great module.

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