Skip to content

Commit da2c715

Browse files
authored
fix(pwa): Replace closeTag parameter with voidTag for HtmlWebpackPlugin (#6518)
HtmlWebpackPlugin has a voidTag parameter that needs to be set to true so that both <link> and <meta> are treated as void elements (with no contents). The closeTag parameter doesn't exist. https://github.com/jantimon/html-webpack-plugin/blob/570f735c237d4a03a65622cfe64652431aca4132/typings.d.ts#L280 https://html.spec.whatwg.org/multipage/syntax.html#void-elements Signed-off-by: Thomas Citharel <tcit@tcit.fr>
1 parent 820b9b7 commit da2c715

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/@vue/cli-plugin-pwa/lib/HtmlPwaPlugin.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -225,10 +225,10 @@ module.exports = class HtmlPwaPlugin {
225225
}
226226
}
227227

228-
function makeTag (tagName, attributes, closeTag = false) {
228+
function makeTag (tagName, attributes, voidTag = true) {
229229
return {
230230
tagName,
231-
closeTag,
231+
voidTag,
232232
attributes
233233
}
234234
}

0 commit comments

Comments
 (0)