title: Using Webpack, can you use Google's closure compiler with HtmlWebpackPlugin?
body: <p>I am currently using Webpack with the HtmlWebpackPlugin to transpile and minify my code and create a HTML document from a template.</p>
  
  <p>I was wondering if there is any way of using Google's closure compiling instead of using babel?</p>
  
  <p><a href="https://www.npmjs.com/package/webpack-closure-compiler" rel="nofollow noreferrer">https://www.npmjs.com/package/webpack-closure-compiler</a></p>
  
  <p>Below is my current plugin code which works with Babel to transpile the code.</p>
  
  <pre><code>plugins:
      new HtmlWebpackPlugin({
          filename: 'TestExport.html',
          template: './Resources/TestExport/TestExportTemplate.html',
          inject: false,
          custom: require("@babel/core").transformSync(fs.readFileSync('./Resources/TestExport/js/custom.js', 'utf8'), {
              "presets": ["@babel/preset-env"]
          }).code,
          style: fs.readFileSync('./Resources/TestExport/css/style.css', 'utf8'),
          minify: {
              html5: true,
              collapseWhitespace: true,
              minifyCSS: true,
              minifyJS: true
          }
      })
  </code></pre>