I would like to modify a piece of javascript that gets loaded by a webpage before that code actually is executed. I know where the line of code I want to modify is, and I can use the browser debugger to set a breakpoint just before that line, however, once the execution is paused I'm unable to modify the script code.
Does anyone know how to achieve this?
PS: Please note that all the rest of the script can remain identical to the original, and I don't want to block all javascript execution, just change a single (or a few) line before my browser runs it.