Is there a way to do Live Expressions in the Safari Debugger? I need to do exactly what is explained in this article, but in Safari.
https://developer.chrome.com/docs/devtools/accessibility/focus/
I know about Safari's watch expressions, but those don't seem to update as I interact with the DOM and clicking the refresh button on the watch expression takes away the focus from DOM elements.
I was looking for the same thing, this workaround was good enough for my use case. In the Safari console:
window.intv = setInterval(() => {
if (window.curEl !== document.activeElement) {
window.curEl = document.activeElement;
console.log(document.activeElement);
}
}, 100);
// when you're done
clearInterval(window.intv);
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With