A webpack-block for html-webpack-plugin.
Version compatibility:
- webpack-blocks v0.x -> webpack-blocks-html v1.x (@latest)
- webpack-blocks v1.x -> DEPRECATED: Merged into webpack-blocks-utils
yarn add --dev webpack-blocks-html
or
npm install --save-dev webpack-blocks-html
import {createConfig, entryPoint, setOutput} from '@webpack-blocks/webpack2'
import babel from '@webpack-blocks/babel6'
import html from './src/webpack-block-html'
export default createConfig([
entryPoint(['babel-polyfill', './src/Main.js']),
setOutput('./build/bundle.js'),
babel(),
html({template: 'assets/index.html'}),
])
See the options list here.
Defaults:
- filename: 'index.html'
- template: 'templates/index.html'
- showErrors: false
This project is licensed under MIT.