gulp-html-replace
gulp-html-replace copied to clipboard
Check if input file is HTML?
Not as much of an issue as a feature request but can it check if the file is html and not attempt the operation if not.
You would just apply your own filter gulp-if for example:
.pipe(gulpif(function (file) {
return !/.html$/.test(file.path);
}, htmlreplace({
... your options
})))
This should be an option, not a default, if implemented. There are reasons to use this with non-HTML files, despite the name.