jaketrent / html-webpack-template

a better default template for html-webpack-plugin
MIT License
830 stars 139 forks source link

HtmlWebpackPlugin key XHTML is ignored #63

Closed LizardKing131313 closed 6 years ago

LizardKing131313 commented 6 years ago

I need render link tags as self-closing. xhtml: true does't working. html-webpack-plugin: 2.30.1 html-webpack-template: 6.1.0 webpack: 3.8.1 My configuration example:

{
  appMountId: 'root',
  chunks: ['app', 'vendor'],
  favicon: path.join(__dirname, '../src/main/resources/images/favicon.ico'),
  filename: '../templates/app.html',
  inject: false,
  minify: {
    collapseInlineTagWhitespace: true,
    collapseWhitespace: true,
    conservativeCollapse: true,
    keepClosingSlash: true,
    minifyCSS: true,
    minifyJS: true,
    minifyURLs: true,
    quoteCharacter: '"',
    removeAttributeQuotes: false
  },
  template: HtmlWebpackTemplate,
  title: 'Application',
  xhtml: true
}

I'm currently use LEGACYHTML5 workaround from nekohtml. Thanks in advance.