4 ms·
> While there are add-ons which block scripts from running entirely, there are no add-ons that I know of which would allow you to run a user-provided alternativ
by gsnedders 12y ago
> While there are add-ons which block scripts from running entirely, there are no add-ons that I know of which would allow you to run a user-provided alternative to a script specified by the web page.
It's a decidedly non-trivial problem problem — how are we identifying a script? Some sites (FB used to, at least) often serve the same scripts from different hostnames (based on what CDN you're connected to, I believe). What happens if the same script (say, jQuery!) is downloaded from two entirely different sites? What if I change some comment, is that still the same script? What if I minify it and variable names change? What if we allow some small semantically equivalent changes? What if the script is non-cacheable and changes on every load (some are!), how do we replace that?
Presto-based desktop releases of Opera would allow you to modify code (and HTML and CSS) on a page identifying it by URL, but I don't know of anything else comparable.