<%= htmlwebpackplugin.options.title="">和<%= htmlwebpackplugin.options.data="">在頁面中顯示不了
老師<%= htmlwebpackplugin.options.title="">和<%= htmlwebpackplugin.options.data="">在頁面中顯示不了,無語了,這和插件的版本有關系么?我這邊在html中用了駝峰方式,另外這個插件其他功能都能用,就是這個模板引擎用不了,求老師解答啊。
老師<%= htmlwebpackplugin.options.title="">和<%= htmlwebpackplugin.options.data="">在頁面中顯示不了,無語了,這和插件的版本有關系么?我這邊在html中用了駝峰方式,另外這個插件其他功能都能用,就是這個模板引擎用不了,求老師解答啊。
2017-04-24
舉報
2018-03-12
<%= htmlwebpackplugin.options.title="">
改為
<%= htmlwebpackplugin.options.title>
2017-09-21
去掉html-loader
2017-06-27
1、npm insall handlebars-loader --save-dev,
2、在配置文件webpack.config.js里添加:
?module: {
? ?loaders: [
? ? ?{
? ? ? ?test: /\.hbs$/,
? ? ? ?loader: 'handlebars-loader'
? ? ?},
? ?]
?},
就可以啦,參考:https://github.com/jantimon/html-webpack-plugin/blob/master/docs/template-option.md
2017-04-26
我用的是2.0的 ?建議全部用2.0的 ?不然感覺不配套