We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a327a5d commit 9a15925Copy full SHA for 9a15925
index.js
@@ -16,7 +16,7 @@ module.exports = function postHTMLParser(html) {
16
17
var parser = new htmlparser.Parser({
18
onprocessinginstruction: function(name, data) {
19
- name === '!doctype' && results.push('<' + data + '>');
+ name.toLowerCase() === '!doctype' && results.push('<' + data + '>');
20
},
21
oncomment: function(data) {
22
var comment = '<!--' + data + '-->',
@@ -63,7 +63,7 @@ module.exports = function postHTMLParser(html) {
63
last.content || (last.content = []);
64
last.content.push(text);
65
}
66
- });
+ }, {lowerCaseTags: false});
67
68
parser.write(html);
69
parser.end();
0 commit comments