summaryrefslogtreecommitdiff
path: root/vendor/github.com
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com')
-rw-r--r--vendor/github.com/tdewolff/minify/v2/README.md1
-rw-r--r--vendor/github.com/tdewolff/parse/v2/html/lex.go4
2 files changed, 5 insertions, 0 deletions
diff --git a/vendor/github.com/tdewolff/minify/v2/README.md b/vendor/github.com/tdewolff/minify/v2/README.md
index 4f601b874..746a20d93 100644
--- a/vendor/github.com/tdewolff/minify/v2/README.md
+++ b/vendor/github.com/tdewolff/minify/v2/README.md
@@ -204,6 +204,7 @@ Options:
- `KeepEndTags` preserve all end tags
- `KeepQuotes` preserve quotes around attribute values
- `KeepWhitespace` preserve whitespace between inline tags but still collapse multiple whitespace characters into one
+- `TemplateDelims` preserve context within and surrounding the given opening and closing delimiters
After recent benchmarking and profiling it became really fast and minifies pages in the 10ms range, making it viable for on-the-fly minification.
diff --git a/vendor/github.com/tdewolff/parse/v2/html/lex.go b/vendor/github.com/tdewolff/parse/v2/html/lex.go
index 8fc9073d8..e3cb9bd04 100644
--- a/vendor/github.com/tdewolff/parse/v2/html/lex.go
+++ b/vendor/github.com/tdewolff/parse/v2/html/lex.go
@@ -184,6 +184,10 @@ func (l *Lexer) Next() (TokenType, []byte) {
} else if c == '!' {
l.r.Move(2)
return l.readMarkup()
+ } else if 0 < len(l.tmplBegin) && l.at(l.tmplBegin...) {
+ l.r.Move(len(l.tmplBegin))
+ l.moveTemplate()
+ l.hasTmpl = true
} else if c == '?' {
l.r.Move(1)
return CommentToken, l.shiftBogusComment()