Permalink
Browse files

Version 3.2.3

1 parent 0c7732e commit 64190178d33882be1a89bcfc332d764f94d8b64c @alexlamsl alexlamsl committed Nov 24, 2016
Showing with 20 additions and 20 deletions.
  1. +11 −11 README.md
  2. +5 −5 dist/htmlminifier.js
  3. +2 −2 dist/htmlminifier.min.js
  4. +1 −1 index.html
  5. +1 −1 package.json
View
@@ -22,19 +22,19 @@ How does HTMLMinifier compare to other solutions — [HTML Minifier from Will Pe
| Site | Original size *(KB)* | HTMLMinifier | minimize | Will Peavy | htmlcompressor.com |
| --------------------------------------------------------------------------- |:--------------------:| ------------:| --------:| ----------:| ------------------:|
-| [Google](https://www.google.com/) | 44 | **43** | 44 | 46 | 45 |
-| [HTMLMinifier](https://github.com/kangax/html-minifier) | 122 | **96** | 104 | 108 | 103 |
-| [CNN](http://www.cnn.com/) | 129 | **118** | 126 | 127 | 122 |
-| [Amazon](http://www.amazon.co.uk/) | 170 | **138** | 162 | 165 | n/a |
-| [BBC](http://www.bbc.co.uk/) | 185 | **151** | 178 | 183 | 174 |
-| [New York Times](http://www.nytimes.com/) | 187 | **124** | 137 | 139 | 132 |
-| [Stack Overflow](http://stackoverflow.com/) | 245 | **189** | 198 | 207 | 196 |
+| [Google](https://www.google.com/) | 44 | **42** | 44 | 46 | 45 |
+| [HTMLMinifier](https://github.com/kangax/html-minifier) | 122 | **96** | 103 | 107 | 103 |
+| [CNN](http://www.cnn.com/) | 132 | **121** | 128 | 129 | 124 |
+| [BBC](http://www.bbc.co.uk/) | 178 | **146** | 172 | 176 | 168 |
+| [Amazon](http://www.amazon.co.uk/) | 185 | **152** | 177 | 179 | n/a |
+| [New York Times](http://www.nytimes.com/) | 195 | **128** | 143 | 145 | 135 |
+| [Stack Overflow](http://stackoverflow.com/) | 244 | **188** | 198 | 206 | 196 |
| [Bootstrap CSS](http://getbootstrap.com/css/) | 276 | **264** | 273 | 231 | 274 |
-| [Wikipedia](https://en.wikipedia.org/wiki/President_of_the_United_States) | 501 | **456** | 484 | 499 | n/a |
-| [NBC](http://www.nbc.com/) | 550 | **528** | 548 | 550 | n/a |
+| [Wikipedia](https://en.wikipedia.org/wiki/President_of_the_United_States) | 499 | **454** | 482 | 498 | n/a |
+| [NBC](http://www.nbc.com/) | 548 | **526** | 546 | 548 | n/a |
| [Eloquent Javascript](http://eloquentjavascript.net/1st_edition/print.html) | 870 | **815** | 840 | 864 | n/a |
-| [ES6 table](http://kangax.github.io/compat-table/es6/) | 4010 | **3374** | 3781 | n/a | n/a |
-| [ES6 draft](https://tc39.github.io/ecma262/) | 5156 | **4594** | 4726 | n/a | n/a |
+| [ES6 table](http://kangax.github.io/compat-table/es6/) | 4113 | **3459** | 3878 | n/a | n/a |
+| [ES6 draft](https://tc39.github.io/ecma262/) | 5157 | **4595** | 4727 | n/a | n/a |
## Options Quick Reference
View
@@ -1,5 +1,5 @@
/*!
- * HTMLMinifier v3.2.0 (http://kangax.github.io/html-minifier/)
+ * HTMLMinifier v3.2.3 (http://kangax.github.io/html-minifier/)
* Copyright 2010-2016 Juriy "kangax" Zaytsev
* Licensed under the MIT license
*/
@@ -33792,16 +33792,16 @@ function normalizeAttr(attr, attrs, tag, options) {
};
}
-function buildAttr(normalized, hasUnarySlash, options, isLast) {
+function buildAttr(normalized, hasUnarySlash, options, isLast, uidAttr) {
var attrName = normalized.name,
attrValue = normalized.value,
attr = normalized.attr,
attrQuote = attr.quote,
attrFragment,
emittedAttrValue;
- if (typeof attrValue !== 'undefined' && !options.removeAttributeQuotes ||
- !canRemoveAttributeQuotes(attrValue)) {
+ if (typeof attrValue !== 'undefined' && (!options.removeAttributeQuotes ||
+ ~attrValue.indexOf(uidAttr) || !canRemoveAttributeQuotes(attrValue))) {
if (!options.preventAttributesEscaping) {
if (typeof options.quoteCharacter === 'undefined') {
var apos = (attrValue.match(/'/g) || []).length;
@@ -34274,7 +34274,7 @@ function minify(value, options, partialMarkup) {
for (var i = attrs.length, isLast = true; --i >= 0;) {
var normalized = normalizeAttr(attrs[i], attrs, tag, options);
if (normalized) {
- parts.unshift(buildAttr(normalized, hasUnarySlash, options, isLast));
+ parts.unshift(buildAttr(normalized, hasUnarySlash, options, isLast, uidAttr));
isLast = false;
}
}
Oops, something went wrong.
View
@@ -9,7 +9,7 @@
<body>
<div id="outer-wrapper">
<div id="wrapper">
- <h1>HTML Minifier <span>(v3.2.0)</span></h1>
+ <h1>HTML Minifier <span>(v3.2.3)</span></h1>
<textarea rows="8" cols="40" id="input"></textarea>
<div class="minify-button">
<button type="button" id="minify-btn">Minify</button>
View
@@ -1,7 +1,7 @@
{
"name": "html-minifier",
"description": "Highly configurable, well-tested, JavaScript-based HTML minifier.",
- "version": "3.2.0",
+ "version": "3.2.3",
"keywords": [
"cli",
"compress",

0 comments on commit 6419017

Please sign in to comment.