Is there a JS instruction to open the browser developer tools?

422 Views Asked by At

I know about the debugger keyword: it works as a breakpoint if the developer tools are already open.

But is there a way to programmatically instruct the web browser to open the developer tools? I've cruised through the MDN docs but haven't found anything.

The use case would be that I need to debug a part of a web that gets opened in a new tab. I can't open it in the same tab and by the time I hit F12 I've already missed the code I'm trying to debug.

0

There are 0 best solutions below