Re:Safari is adopting an extensions API similar to Firefox’s...
by stephenr on Tuesday June 23, 2020 @03:56PM
(#23619414)
Does network filtering not rely on JavaScript now?
Re:Safari is adopting an extensions API similar to Firefox’s...
by aswan on Tuesday June 23, 2020 @04:04PM
(#23619521)
The webRequest api uses javascript, but with code that runs in the context of the extension, not code that is injected into web pages.
You can read a bit more here:
https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/Web...
Re:Safari is adopting an extensions API similar to Firefox’s...
by stephenr on Wednesday June 24, 2020 @01:12AM
(#23624334)
Great so not javascript running "in the context" of the page.. just javascript running.. somewhere else, for every single network request that is made, and that still has access to the page.
I know a lot of web developers don't want to hear this, but throwing more javascript at the problem isn't always the best solution.
However, this API could be used to optimize some of (not all of) the networking filtering that uBO does. Network filtering is distinct from cosmetic filtering, the latter is what injects scripts into every page. The uBO wiki has some nice documentation of the different features, measurements of their overhead, etc. E.g.: https://github.com/gorhill/uBlock/wiki/Doesn't-uBlock-Origin...