taoqf / node-html-parser

A very fast HTML parser, generating a simplified DOM, with basic element query support.
MIT License
1.12k stars 112 forks source link

Inserting rawTagName property of HTMLElement #90

Closed andrelmlins closed 3 years ago

taoqf commented 3 years ago

Thank you for your work, but I am really sorry I would not merge this. I will add some document about property tagName, not rawTagName, because rawTagName is not meant to be used by end users. Actually I should make rawTagName private, but I won't because Typescript is not sopport friend yet. Because I used toUppercase in tagName (as the same behavior in browser), so use rawTagName in parse is a little faster then tagName. If ts support friend I would use it, But for now, I would like to use public, and hide it from document. Thanks again. Let me know if you have any other idea about this.

andrelmlins commented 3 years ago

Ok @taoqf , I will analyze the tagName.