Skip to content

Instantly share code, notes, and snippets.

@pinglinh
Last active March 12, 2018 14:54
Show Gist options
  • Save pinglinh/968a6d80f2c18e3f11e0bd298b11c3ab to your computer and use it in GitHub Desktop.
Save pinglinh/968a6d80f2c18e3f11e0bd298b11c3ab to your computer and use it in GitHub Desktop.
const HtmlWebPackPlugin = require("html-webpack-plugin");
const htmlPlugin = new HtmlWebPackPlugin({
template: "./src/index.html",
filename: "./index.html"
});
module.exports = {
module: {
rules: [
{
test: /\.js$/,
exclude: /node_modules/,
use: {
loader: "babel-loader"
}
}
]
},
plugins: [htmlPlugin]
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment