ktsn / vue-template-loader

Vue.js 2.0 template loader for webpack
MIT License
266 stars 26 forks source link

html-webpack-plugin require html-loader #3

Closed fallenleavesguy closed 7 years ago

fallenleavesguy commented 7 years ago

html-webpack-plugin require html-loader, so I can't replace

{
  test: /\.html$/,
  use: ['html-loader']
}

with

{
  test: /\.html$/,
  use: ['vue-template-loader']
}
ktsn commented 7 years ago

If you mean you have two types of html files - one is for vue template the other is for any other purpose - you can use include/exclude option to separate their matching.

{
  test: /\.html$/,
  use: ['html-loader'],
  include: /static/
},
{
  test: /\.html$/,
  use: ['vue-template-loader'],
  include: /components/
}
fallenleavesguy commented 7 years ago

just work