htmlnano 1.1.0 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,7 +3,13 @@ All notable changes to this project will be documented in this file.
3
3
  This project adheres to [Semantic Versioning](http://semver.org/).
4
4
 
5
5
 
6
+ ## [1.1.1] - 2021-09-19
7
+ This version fixes fatal errors introduced in [1.1.0].
8
+
9
+
6
10
  ## [1.1.0] - 2021-09-19
11
+ *This version contains fatal errors. Please use [1.1.1] instead.*
12
+
7
13
  ### Added
8
14
  - Collapse missing value default attribute in `removeRedundantAttributes` [#158].
9
15
  - New `normalizeAttributeValues` module to normalize casing of attribute values [#163].
@@ -219,6 +225,7 @@ Otherwise, you have to adapt the config according to the new [PurgeCSS@3](https:
219
225
  - Remove attributes that contains only white spaces.
220
226
 
221
227
 
228
+ [1.1.1]: https://github.com/posthtml/htmlnano/compare/1.1.0...1.1.1
222
229
  [1.1.0]: https://github.com/posthtml/htmlnano/compare/1.0.1...1.1.0
223
230
  [1.0.1]: https://github.com/posthtml/htmlnano/compare/1.0.0...1.0.1
224
231
  [1.0.0]: https://github.com/posthtml/htmlnano/compare/0.2.9...1.0.0
@@ -1,5 +1,5 @@
1
1
  {
2
- "version-1.1.0/tutorialSidebar": [
2
+ "version-1.1.1/tutorialSidebar": [
3
3
  {
4
4
  "type": "autogenerated",
5
5
  "dirName": "."
@@ -1,3 +1,3 @@
1
1
  [
2
- "1.1.0"
2
+ "1.1.1"
3
3
  ]
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.default = collapseAttributeWhitespace;
7
7
  exports.attributesWithLists = void 0;
8
8
 
9
- var _helpers = require("../helpers.es6");
9
+ var _helpers = require("../helpers");
10
10
 
11
11
  const attributesWithLists = new Set(['class', 'dropzone', 'rel', // a, area, link
12
12
  'ping', // a, area
@@ -7,7 +7,7 @@ exports.default = minifyJs;
7
7
 
8
8
  var _terser = _interopRequireDefault(require("terser"));
9
9
 
10
- var _helpers = require("../helpers.es6");
10
+ var _helpers = require("../helpers");
11
11
 
12
12
  var _removeRedundantAttributes = require("./removeRedundantAttributes");
13
13
 
@@ -39,7 +39,7 @@ function normalizeAttributeValues(tree) {
39
39
  const attrNameLower = attrName.toLowerCase();
40
40
 
41
41
  if (Object.hasOwnProperty.call(caseInsensitiveAttributes, attrNameLower) && (caseInsensitiveAttributes[attrNameLower] === null || caseInsensitiveAttributes[attrNameLower].includes(node.tag))) {
42
- node.attrs[attrName] = attrValue.toLowerCase();
42
+ node.attrs[attrName] = attrValue.toLowerCase ? attrValue.toLowerCase() : attrValue;
43
43
  }
44
44
  });
45
45
  return node;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "htmlnano",
3
- "version": "1.1.0",
3
+ "version": "1.1.1",
4
4
  "description": "Modular HTML minifier, built on top of the PostHTML",
5
5
  "main": "index.js",
6
6
  "author": "Kirill Maltsev <maltsevkirill@gmail.com>",