Open thephilgray opened 5 years ago
still needs to encode certain entities, which get decoded by pug compile.
in my latest project, I was able to replace htmltidy with prettier and ensure that the ampersand is always encoding using gulp-converter-character-entities like this:
gulp-converter-character-entities
// .pipe( // htmltidy({ // literalAttributes: true, // "drop-empty-elements": "no", // "wrap-attributes": false // }) // ) .pipe( convert({ entity: { "&": "&" } }) ) .pipe(prettier({ parser: "html" }))
still needs to encode certain entities, which get decoded by pug compile.
in my latest project, I was able to replace htmltidy with prettier and ensure that the ampersand is always encoding using
gulp-converter-character-entities
like this: