Closed odensc closed 6 years ago
The gist of it is that you were listening on document.body
, but the comment elements are too deep in the DOM to be picked up by that. If you enabled subtree: true
it would have worked, but it would be pretty inefficient - so I listened on the parent element of the comments.
got it, i thought that child
(or however that setting was, maybe childrens
) was enough to have it iterate through the whole thing.
However yeah, it would have been definitely not optimised, thanks again!
Hey, thanks for that, it works (although I need to find some time to read it properly and understand why mine wasn't) except an error when you're in a page that is not a topic page.
I'll merge it and add a check so that it run only when in a topic's page that is where we've the issue anyway :)