after having used noscript for a very long time, I am now building my own web extension that aims to ease up web scraping tasks. This isn't intended to be a shameless ad, I promise. I just wanted to let you know of this way, so that maybe you can speed up noscript, too.
Today I found a way to block script elements from loading that doesn't necessarily rely on the Content-Security-Policy and instead uses a MutationObserver on the document.documentElement ( node) as a content script that is injected at document_start.
The MutationObserver then simply blocks all addedNodes[] that have a node.tagName == "SCRIPT" (or are conditional comments) and removes them immediately from their parentNode. This leads to no JS being executed at all, and also doesn't load anything via HTTP. Additionally this ensures that Githubissues.
Githubissues is a development platform for aggregating issues.
Hey there,
after having used noscript for a very long time, I am now building my own web extension that aims to ease up web scraping tasks. This isn't intended to be a shameless ad, I promise. I just wanted to let you know of this way, so that maybe you can speed up noscript, too.
Today I found a way to block script elements from loading that doesn't necessarily rely on the
Content-Security-Policy
and instead uses aMutationObserver
on thedocument.documentElement
( node) as a content script that is injected atdocument_start
.The MutationObserver then simply blocks all
addedNodes[]
that have anode.tagName == "SCRIPT"
(or are conditional comments) and removes them immediately from their parentNode. This leads to no JS being executed at all, and also doesn't load anything via HTTP. Additionally this ensures that Githubissues.