grunt-hash | grunt plugin for appending hashes | Caching library
kandi X-RAY | grunt-hash Summary
kandi X-RAY | grunt-hash Summary
a grunt plugin for appending hashes to files for cache busting
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of grunt-hash
grunt-hash Key Features
grunt-hash Examples and Code Snippets
Community Discussions
Trending Discussions on grunt-hash
QUESTION
I'm new in Grunt (or any task manager) ;)
I have issue with filename ex: styles.css?v=1feafc7?v=1feafc7&v=1feafc7&v=8aa4f4b
Grunt adds me many v=
when I run tasks many times.
I expect that it will be preserved only newest version, not all of them.
That's my hash_res
config
ANSWER
Answered 2020-May-04 at 11:18OK, I found solution here
The problem you're seeing is because the task is processing the same files over and over. It's recommended that the process for running these tasks is:
copy files to a new folder -> process files in there -> deploy that version of the code
QUESTION
I am working on a Koa.js application with Pug as the template engine. I would like to create an automated process so that the production templates have the URLs of the JavaScript and CSS files updated with fingerprinted names and a base URL to a certain CDN provider. I have found a plugin for gulp (gulp-jade-usemin) to replace the references of non-optimized scripts or stylesheets, but after that I would like to update the optimized references with the fingerprinted version in a CDN provider.
I have set up in the past a similar process for an Express application with Swig as the template engine using a bunch of grunt plugins (grunt-contrib-copy, grunt-hashres, grunt-processhtml, grunt-cdn), but I cannot find a way to set up something similar with Pug, mainly because the templates are not natively HTML.
I am willing to use grunt, gulp or any other automation tool.
...ANSWER
Answered 2017-May-19 at 19:26Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install grunt-hash
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page