1.0.4 • Published 5 years ago
auto-timestamp-assets v1.0.4
auto-timestamp-assets
this is a tool for old web-project which assets(js,css,png...) and page(html,cshtml,jsp) are separated.
useage
npm install -g auto-timestamp-assets
then you could run the tool anywhere you want(in your project folder for the best)
run the command in the right place
auto-timestamp watch
eg:
- my assets file is F:\d\a\c.js
- the page file is F:\d\b\e.cshtml,F:\d\b\f.cshtml,F:\d\b\g\t.cshtml
- in both of the page file ,i have the quote:
<script src="~/a/c.js"></script>
- i need to run the command in f:\d,and set sourceFolder to 'a'
now when you change you assets and save it,page will auto add timestamp (eg:?v=1554950157381)
notice
auto-timestamp --help
for more details