thoro
thoro

Reputation: 407

Chrome 80: Pause script execution (F8) does not work when DevTools is not focused

since Chrome 80 I cannot pause the script execution when the focus is on the website I'm developing. This is extremely inconvenient e.g. when debugging hover effects.

Does anyone else experience this issue or has more information about it? Maybe a feature flag deep inside the browser settings?

Update

This was fixed in Chrome 83.

Upvotes: 20

Views: 14302

Answers (4)

Oleksandr Makarenko
Oleksandr Makarenko

Reputation: 808

WORKAROUND

You can use option Break on -> subtree modifications

It helps me to stop script execution instead of using f8 functionality.

Steps: 1. Turn on 'Break on' for element you need to debug 2. Make some changes (hover or open drop down list as in my situation) 3. Browser will pause script execution

I turn on this for debugged element

Upvotes: 5

Arun Balan
Arun Balan

Reputation: 1

Use Ctrl+\ to pause the debugger. It works.

Upvotes: -6

Roland Soós
Roland Soós

Reputation: 3280

Until it is fixed, you can use the following in your app:

document.addEventListener('keydown', function (e) {
    if (e.keyCode == 119) { // F8
        debugger;
    }
}, {
    capture: true
});

Upvotes: 32

thoro
thoro

Reputation: 407

It's a bug in Chrome, I found the bugreport here:

https://bugs.chromium.org/p/chromium/issues/detail?id=1049910&q=f8&can=2

Upvotes: 4

Related Questions