You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Dec 1, 2017. It is now read-only.
files specified in assets field (e.g. app.use(assets,{}) )start all with the prefix static/ (the folder 'static/' is in the root of the project; I did it for the integration with tools of minification, like grunt-uglify)
the path specified in tag cachify('<path>') starts without the prefix static/, because the server serves static files directly from the static folder static/ (so if the file in assets field is specified like 'static/file1.js', the path in the views the server serves is '/file1.js' )
for this mismatching the method prod_or_dev_tags was failing in creating the right tags for the asset files
I solved adding in the options object a field myprefix. In this way the method prod_or_dev_tags can always understand how to serve properly asset files.
I didn't use the option url_to_paths because I had to specify too much stuff.
If it's worth to be integrated with the master repository let me know.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
My conf is like this:
var cachify = require('connect-cachify') app.use(cachify.setup( getAllWithPublicAsRoot() , { root: path.join(__dirname, 'public'), production: false }));
where getAllWithPublicAsRoot returns an object like:
{ "/js/files.min.js":['/js/file1.js', '/js/file2.js'] }
where js folder is in public folder.
But if I see the html code in the page, it puts in the html
/js/files.min.js
, not the corresponding files specified in the corresponding array.I'm using connect-cachify 0.0.15
The text was updated successfully, but these errors were encountered: