gulp-tpl-rev
Advanced tools
Comparing version 1.1.0 to 1.2.0
@@ -40,3 +40,3 @@ "use strict"; | ||
var rewriter_1 = new parse5_html_rewriting_stream_1.default(); | ||
rewriter_1.on('startTag', function (token) { | ||
rewriter_1.on('startTag', function (token, html) { | ||
var attr; | ||
@@ -57,4 +57,7 @@ if (token.tagName === 'link') { | ||
} | ||
rewriter_1.emitStartTag(token); | ||
} | ||
rewriter_1.emitStartTag(token); | ||
else { | ||
rewriter_1.emitRaw(html); | ||
} | ||
}); | ||
@@ -61,0 +64,0 @@ rewriter_1.on("text", function (token) { |
{ | ||
"name": "gulp-tpl-rev", | ||
"version": "1.1.0", | ||
"version": "1.2.0", | ||
"description": "template resource url revisioning by appending content hash to filenames: unicorn.css => unicorn.css?_v=1", | ||
"main": "dist/index.js", | ||
"typings": "plugin.ts", | ||
"scripts": { | ||
@@ -8,0 +7,0 @@ "prepublishOnly": "npm run compile", |
@@ -23,5 +23,3 @@ # gulp-tpl-rev [![Build Status](https://api.travis-ci.org/kwoktung/gulp-tpl-rev.svg?branch=master)](https://travis-ci.org/kwoktung/gulp-tpl-rev) | ||
gulp.src('src/*.html') | ||
.pipe(tpl({ | ||
name: '_v', | ||
hash: function(pathname) { | ||
.pipe(tpl( function(pathname) { | ||
const { ext } = path.parse(pathname) | ||
@@ -37,5 +35,5 @@ const fullpath = path.join(__dirname, 'wwwroot', pathname) | ||
} | ||
})) | ||
)) | ||
.pipe(gulp.dest('dist')) | ||
); | ||
``` | ||
``` |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5182
84
38