javascript - How to know if a certain Node is the Head of an HTML document? -


i'm working on chrome extension add features existing page. that, need add script page as possible!! (no, cannot run content script starts before everything, need particular script inserted into dom)

(why? because page loads everythin using ajax calls, , need able perform operations before calls)

so intent add script sooner can after head of document appears.

i'm looking @ mutationsobserver, , seems job. how can check if node addednodes collection head???

since looks maybe provided answer actual problem, i'll post answer.

you can use chrome plug-in api directly intercept ajax requests using this: https://developer.chrome.com/extensions/webrequest


Comments

Popular posts from this blog

OpenCV OpenCL: Convert Mat to Bitmap in JNI Layer for Android -

android - org.xmlpull.v1.XmlPullParserException: expected: START_TAG {http://schemas.xmlsoap.org/soap/envelope/}Envelope -

python - How to remove the Xframe Options header in django? -