@node-minify/html-minifier 7.0.0 → 7.1.0

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.
@@ -1,11 +1,8 @@
1
1
  "use strict";
2
2
 
3
3
  var _htmlMinifier = _interopRequireDefault(require("html-minifier"));
4
-
5
4
  var _utils = require("@node-minify/utils");
6
-
7
5
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
8
-
9
6
  /*!
10
7
  * node-minify
11
8
  * Copyright(c) 2011-2022 Rodolphe Stoclin
@@ -37,6 +34,7 @@ const defaultOptions = {
37
34
  removeStyleLinkTypeAttributes: true,
38
35
  useShortDoctype: true
39
36
  };
37
+
40
38
  /**
41
39
  * Run html-minifier.
42
40
  *
@@ -44,7 +42,6 @@ const defaultOptions = {
44
42
  * @param {String} content
45
43
  * @param {Function} callback
46
44
  */
47
-
48
45
  const minifyHTMLMinifier = ({
49
46
  settings,
50
47
  content,
@@ -53,7 +50,6 @@ const minifyHTMLMinifier = ({
53
50
  }) => {
54
51
  const options = Object.assign({}, defaultOptions, settings.options);
55
52
  const contentMinified = HTMLMinifier(content, options);
56
-
57
53
  if (!settings.content) {
58
54
  _utils.utils.writeFile({
59
55
  file: settings.output,
@@ -61,16 +57,13 @@ const minifyHTMLMinifier = ({
61
57
  index
62
58
  });
63
59
  }
64
-
65
60
  if (callback) {
66
61
  return callback(null, contentMinified);
67
62
  }
68
-
69
63
  return contentMinified;
70
64
  };
65
+
71
66
  /**
72
67
  * Expose `minifyHTMLMinifier()`.
73
68
  */
74
-
75
-
76
69
  module.exports = minifyHTMLMinifier;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@node-minify/html-minifier",
3
- "version": "7.0.0",
3
+ "version": "7.1.0",
4
4
  "description": "html-minifier plugin for @node-minify",
5
5
  "keywords": [
6
6
  "compressor",
@@ -33,8 +33,8 @@
33
33
  "url": "https://github.com/srod/node-minify/issues"
34
34
  },
35
35
  "dependencies": {
36
- "@node-minify/utils": "^7.0.0",
36
+ "@node-minify/utils": "^7.1.0",
37
37
  "html-minifier": "4.0.0"
38
38
  },
39
- "gitHead": "8b5bda6f1ac9fe7180006f2a19ec3253e8fff4ec"
39
+ "gitHead": "94cef2d5d653c3bddc3e603b4e25c135b0b6f4b3"
40
40
  }