I'm using grunt
to build a javascript/angularjs
project in the following order:
clean copy > uglify > cssmin
.
Now if I change a js
file I'd always have to manually add a version increment at the end of the script tag, so that the browser can detect the changes.
<script src="/js/myscript?v123"></script>
Question: how can I automate this process using grunt
? If I run the "grunt" command, only files that changed compared to the last run should get a version increment. So that the browser can reuse the cached files as much as possible.