camwiegert/in-view

Run MutationObserver on contentLoaded event

paolocavanna opened this issue · 4 comments

If the script is loaded into the <head>, the instantiation of MutationObserver, done on line 51 of in-view.js, should be done inside a DOMContentLoaded event, to prevent the following error:
Uncaught TypeError: Failed to execute 'observe' on 'MutationObserver': parameter 1 is not of type 'Node'.

same with me

@paolocavanna Thanks for the heads up. Will move to patch this ASAP.

Alright, this should be all patched in v0.6.1. Thanks!

Great man!