Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Black-boxing script option in Chrome Developer tool

I have an issue with the Chrome developer tool.
My version is Version 46.0.2490.71 (64-bit)
According to online tutorials, I can go to Sources tab, right-click a script file and there will be Blackbox Script option to choose. enter image description here
However, I see no option in my chrome. How do I enable that option since I have no knowledge about regex?

noBlackBoxoption



Another problem: The scripts still got debugged even though I added them to blackbox list. Weird!!



VMFile One more thing i want to ask is how I blackbox an "unlimited" amount of VM files?

like image 782
phuwin Avatar asked Oct 20 '15 11:10

phuwin


1 Answers

  1. Open devtools settings (press F1 once in devtools or open from the menu)
  2. Go to blackboxing (see image below) enter image description here

  3. Add a pattern, for example:

    • node_modules
    • angular
    • rxjs

It uses regex syntax in case you need something more specific.

The nice part about blackboxing library/framework scripts is that it makes it easier to see in stacktraces from where the error was triggered in your own sources.

EDIT

As other pointed out, since this answer was posted you can directly blackbox a script with a right click on the source file in devtools. However head off to the blackboxing settings UI for more control.

enter image description here

like image 106
Michael P. Bazos Avatar answered Sep 30 '22 20:09

Michael P. Bazos