querySelector/querySelectorAll not available on DocumentFragment
fortes opened this issue · 4 comments
fortes commented
domino = require('domino');
window = domino.createWindow('');
frag = window.document.createDocumentFragment()
frag.querySelector // Undefined
cscott commented
Seems legit: http://www.w3.org/TR/selectors-api/ specifies that Document, DocumentFragment, and Element are supposed to have this API. Patch welcome!
fortes commented
Took a quick look, and looks like the lack of getElementsByTagName
and a few other functions means this isn't a quick fix for someone that doesn't know the codebase like me. Perhaps when I have more time.
cscott commented
Ok, latest git HEAD should fix your problem. Can you check it out and close this bug if it works for you? (I added a simple test case, so it seems to work for me!)
fortes commented
Works for me on HEAD. Thanks for the speedy fix!