Gathering detailed insights and metrics for @vxna/mini-html-webpack-template
Gathering detailed insights and metrics for @vxna/mini-html-webpack-template
Gathering detailed insights and metrics for @vxna/mini-html-webpack-template
Gathering detailed insights and metrics for @vxna/mini-html-webpack-template
Minimum viable template for mini-html-webpack-plugin
npm install @vxna/mini-html-webpack-template
Typescript
Module System
Min. Node Version
Node Version
NPM Version
98.8
Supply Chain
99.4
Quality
75.7
Maintenance
100
Vulnerability
100
License
JavaScript (100%)
Total Downloads
30,828,663
Last Day
2,563
Last Week
49,003
Last Month
210,464
Last Year
2,678,148
MIT License
12 Stars
41 Commits
2 Forks
1 Watchers
1 Branches
2 Contributors
Updated on Sep 02, 2020
Minified
Minified + Gzipped
Latest Version
2.0.0
Package Id
@vxna/mini-html-webpack-template@2.0.0
Size
3.45 kB
NPM Version
6.13.4
Node Version
12.14.1
Published on
Jan 31, 2020
Cumulative downloads
Total Downloads
Last Day
-17.7%
2,563
Compared to previous day
Last Week
-11.1%
49,003
Compared to previous week
Last Month
-1.4%
210,464
Compared to previous month
Last Year
-37%
2,678,148
Compared to previous year
Template for mini-html-webpack-plugin that extends default features with useful subset of options
It does not work with html-webpack-plugin
webpack.config.js
1const MiniHtmlWebpackPlugin = require('mini-html-webpack-plugin') 2 3module.exports = { 4 plugins: [ 5 new MiniHtmlWebpackPlugin({ 6 context: { 7 title: 'common-usage', 8 favicon: 'https://assets-cdn.github.com/favicon.ico', 9 container: 'root', 10 trimWhitespace: true 11 }, 12 template: require('@vxna/mini-html-webpack-template') 13 }) 14 ] 15}
Name | Type | Default | Description |
---|---|---|---|
lang | {String} | undefined | Set document language |
title | {String} | 'sample-app' | Set document title |
favicon | {String} | undefined | Set document favicon |
container | {String} | undefined | Set application mount point |
trimWhitespace | {Boolean} | undefined | Safe document whitespace reduction |
webpack.config.js
1const MiniHtmlWebpackPlugin = require('mini-html-webpack-plugin') 2 3module.exports = { 4 plugins: [ 5 new MiniHtmlWebpackPlugin({ 6 context: { 7 title: 'extended-usage', 8 head: { 9 meta: [ 10 { 11 name: 'description', 12 content: 'mini-html-webpack-template' 13 } 14 ] 15 }, 16 body: { 17 raw: '<div id="root"></div>' 18 }, 19 attrs: { 20 js: { 21 async: '', 22 type: 'text/javascript' 23 } 24 } 25 }, 26 template: require('@vxna/mini-html-webpack-template') 27 }) 28 ] 29}
Name | Type | Default | Description |
---|---|---|---|
head.meta | {Array} | undefined | Array of objects with key + value pairs |
head.links | {Array} | undefined | Array of objects with key + value pairs |
head.scripts | {Array} | undefined | Array of objects with key + value pairs |
head.raw | {Array|String} | undefined | Generates raw document markup |
body.scripts | {Array} | undefined | Array of objects with key + value pairs |
body.raw | {Array|String} | undefined | Generates raw document markup |
attrs.js | {Object} | undefined | Applies html attributes to webpack output |
attrs.css | {Object} | undefined | Applies html attributes to webpack output |
For custom needs html-minifier middleware and all of it's options could be used
webpack.config.js
1const { minify } = require('html-minifier') 2const MiniHtmlWebpackPlugin = require('mini-html-webpack-plugin') 3 4module.exports = { 5 plugins: [ 6 new MiniHtmlWebpackPlugin({ 7 context: { 8 title: 'advanced-minification' 9 }, 10 template: ctx => 11 minify(require('@vxna/mini-html-webpack-template')(ctx), { 12 collapseWhitespace: true, 13 minifyCSS: true, 14 minifyJS: true 15 }) 16 }) 17 ] 18}
SRI is out of scope of this project and it's recommended to use html-webpack-plugin with it's ecosystem tools.
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
no dangerous workflow patterns detected
Reason
license file detected
Details
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
Found 1/29 approved changesets -- score normalized to 0
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
50 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-06-09
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More