WebReflection / basicHTML

A NodeJS based, standard oriented, HTML implementation.
ISC License
126 stars 10 forks source link

Enable external selectors library #13

Closed WebReflection closed 6 years ago

WebReflection commented 6 years ago

Usable selectors are very few in core and more than once users asked for more complex selectors.

The use case is using basicHTML for testing and code-covering purposes, where complex selectors might be actually useful.

Find a way to pass along querySelector and querySelectorAll engine through the ParentNode interface.

WebReflection commented 6 years ago

actually, this went up easier than I thought. Sizzle is now tested and linked as example. Readme improved too: https://github.com/WebReflection/basicHTML#about-current-caveats-

I think I'm done here, any hook would need to simply do the exact same trick showed in the example.

Thinking for a day, then closing if I realise this is enough.

WebReflection commented 6 years ago

I have simplified initialisation with the ability to include a custom selector through the .init(...) method as described in the README: https://github.com/WebReflection/basicHTML#new-init-in-013