https://github.com/h-ikeda/html-webpack-polyfills-plugin
Inject <script> tag that references polyfill service (https://polyfill.io) to html via HTML Webpack Plugin.
https://github.com/h-ikeda/html-webpack-polyfills-plugin
Last synced: 3 months ago
JSON representation
Inject <script> tag that references polyfill service (https://polyfill.io) to html via HTML Webpack Plugin.
- Host: GitHub
- URL: https://github.com/h-ikeda/html-webpack-polyfills-plugin
- Owner: h-ikeda
- License: mit
- Created: 2017-05-16T22:46:40.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2021-05-07T17:47:33.000Z (about 4 years ago)
- Last Synced: 2025-02-14T02:56:32.344Z (4 months ago)
- Language: JavaScript
- Size: 223 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 11
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# HTML Webpack Polyfills Plugin
[](https://circleci.com/gh/h-ikeda/html-webpack-polyfills-plugin) [](https://www.codacy.com/app/h-ikeda/html-webpack-polyfills-plugin?utm_source=github.com&utm_medium=referral&utm_content=h-ikeda/html-webpack-polyfills-plugin&utm_campaign=Badge_Grade) [](https://greenkeeper.io/)
Inject <script> tag that references polyfill service (https://polyfill.io) to html via HTML Webpack Plugin.
## Usage
On webpack.config.js,
```
const HtmlWebpackPlugin = require("html-webpack-plugin");
const HtmlWebpackPolyfillsPlugin = require("html-webpack-polyfills-plugin");module.exports = {
// ...
plugins: [
new HtmlWebpackPlugin(),
new HtmlWebpackPolyfillsPlugin()
]
}
```
This configuration create index.html file containing script tag as below,
``.If you want to customize URL, pass options object to constructor.
```
new HtmlWebpackPolyfillsPlugin({
minify: false
})
```
## Options
Options below are available.
### minify
type: boolean
default: true
### type
type: string
default: "js"
### features
type: Array or string
default: undefined