Socket
Socket
Sign inDemoInstall

html-loader

Package Overview
Dependencies
Maintainers
3
Versions
37
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

html-loader - npm Package Compare versions

Comparing version 3.0.1 to 3.1.0

3

dist/cjs.js

@@ -6,2 +6,3 @@ "use strict";

module.exports = loader.default;
module.exports.raw = loader.raw;
module.exports.raw = loader.raw;
module.exports.defaultMinimizerOptions = loader.defaultMinimizerOptions;

@@ -7,2 +7,8 @@ "use strict";

exports.default = loader;
Object.defineProperty(exports, "defaultMinimizerOptions", {
enumerable: true,
get: function () {
return _utils.defaultMinimizerOptions;
}
});

@@ -9,0 +15,0 @@ var _plugins = require("./plugins");

@@ -7,2 +7,3 @@ "use strict";

exports.c0ControlCodesExclude = c0ControlCodesExclude;
exports.defaultMinimizerOptions = void 0;
exports.getExportCode = getExportCode;

@@ -486,2 +487,3 @@ exports.getFilter = getFilter;

};
exports.defaultMinimizerOptions = defaultMinimizerOptions;

@@ -488,0 +490,0 @@ function getMinimizeOption(rawOptions, loaderContext) {

{
"name": "html-loader",
"version": "3.0.1",
"version": "3.1.0",
"description": "Html loader module for webpack",

@@ -49,29 +49,29 @@ "license": "MIT",

"devDependencies": {
"@babel/cli": "^7.14.5",
"@babel/core": "^7.14.6",
"@babel/preset-env": "^7.14.7",
"@babel/cli": "^7.16.7",
"@babel/core": "^7.16.7",
"@babel/preset-env": "^7.16.7",
"@commitlint/cli": "^14.1.0",
"@commitlint/config-conventional": "^14.1.0",
"@webpack-contrib/eslint-config-webpack": "^3.0.0",
"babel-jest": "^27.0.5",
"babel-jest": "^27.4.5",
"cross-env": "^7.0.3",
"del": "^6.0.0",
"del-cli": "^4.0.0",
"es-check": "^6.0.0",
"eslint": "^8.0.1",
"es-check": "^6.1.1",
"eslint": "^8.6.0",
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-import": "^2.23.4",
"eslint-plugin-import": "^2.25.4",
"handlebars": "^4.7.7",
"html-webpack-plugin": "^5.3.2",
"husky": "^7.0.0",
"jest": "^27.0.5",
"jest": "^27.4.5",
"lint-staged": "^11.0.0",
"memfs": "^3.2.2",
"memfs": "^3.4.1",
"npm-run-all": "^4.1.5",
"posthtml": "^0.16.4",
"posthtml-webp": "^2.1.0",
"prettier": "^2.3.1",
"prettier": "^2.5.1",
"standard-version": "^9.3.0",
"unescape-unicode": "^0.2.0",
"webpack": "^5.40.0"
"webpack": "^5.65.0"
},

@@ -78,0 +78,0 @@ "keywords": [

@@ -537,3 +537,3 @@ <div align="center">

The rules can be disabled using the following options in your `webpack.conf.js`
The default rules can be overridden using the following options in your `webpack.conf.js`

@@ -561,2 +561,28 @@ **webpack.config.js**

The default rules can be extended:
**webpack.config.js**
```js
const { defaultMinimizerOptions } = require("html-loader");
module.exports = {
module: {
rules: [
{
test: /\.html$/i,
loader: "html-loader",
options: {
minimize: {
...defaultMinimizerOptions,
removeComments: false,
collapseWhitespace: false,
},
},
},
],
},
};
```
### `esModule`

@@ -563,0 +589,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc