Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to disable chrome extensions JS when debugging in devtools?

When I add mouse event breakpoint, devtools always jump into extension's JS.

Is there any way to point to my mouse event code directly?

like image 388
barcahead Avatar asked Jan 14 '12 12:01

barcahead


People also ask

How do I disable developer mode extensions in Chrome?

Pack your extension ( chrome://extensions/ , tick at 'Developer mode', hit 'Pack extension...') and install it via drag-and-dropping the . crx file into the chrome://extensions page. (Since the extension is not from Chrome Web Store, it will be disabled by default.)


1 Answers

The only way to disable the script (e.g. to avoid side-effects) is by disabling the extension (for instance, by using incognito mode if the extension is not enabled in incognito mode).

If you don't mind the scripts to run, but want to ignore extension code, then you can use the script blackboxing feature of Chrome's devtools.

If you never develop extensions and aren't interested in stepping through it, then open the settings menu of the devtools, click on Blackboxing and then the "Blackbox content scripts" checkbox:

If you only want to selectively ignore files, then you can also right-click on the source of the file that you want to ignore, and click on the "Blackbox Script" contextmenu option. To remove the pattern, go to the "Blackboxing" settings panel as shown before.

like image 181
Rob W Avatar answered Oct 06 '22 00:10

Rob W