Closed arturkin closed 11 months ago
Thought I'd have a look at this - good news it's possible. :) Instead of using jade-html-loader, use template-html-loader (you also need jade installed).
This is the webpack config that worked for me:
var IndexHtmlPlugin = require('indexhtml-webpack-plugin');
module.exports = {
entry: {
"index.html": './src/index.jade',
main: "./src/main.js"
},
output: {
path: "./build",
filename: "[name]-[chunkhash].js"
},
module: {
loaders: [
{
test: /index\.jade$/,
loader: 'template-html-loader'
}
]
},
plugins: [
new IndexHtmlPlugin('index.html', 'index.html')
]
}
Thanks, it works but without HMR :(
Yes, works. But i want HMR. Please fixed.
It would be a good addition to this plugin to work with template engines like
jade
. I triedjade-html-loader
but no luck.