b-fuze / deno-dom

Browser DOM & HTML parser in Deno
https://jsr.io/@b-fuze/deno-dom
MIT License
423 stars 47 forks source link

Improve error message when misusing protected `Node._shallowClone` method #176

Open chances opened 3 months ago

b-fuze commented 3 months ago

I'm not opposed to merging this but ideally there would be a way to prevent people from using these private methods to begin with. I should be using private in TypeScript but that makes certain things a pain, aside from that I was hoping that having an underscore would discourage people from using them...

What probably needs to happen is that I need to either remove them from the public API type information or just refactor them as utility functions...