Safari浏览器(iPhone模拟器):如何查看/监控所有被触发的事件? [英] Safari Browser (iPhone Simulator): How to see/monitor all events being triggered?
问题描述
我在Safari OSX中使用iPhone模拟器来调试我的JavaScript。我正在使用控制台,因为页面上有许多事件处理程序(另外我想看看浏览器是否还会触发任何其他事件,例如:悬停在触摸上),看看ANY会非常有用/所有事件都是实时触发的。我发现了一篇关于如何在Firefox / FireBug中做到这一点的文章......对于Safari / iPhone模拟器来说这是什么?谢谢!
monitorEvents
也适用于Safari(iOS 11)。
I'm using the iPhone Simulator in Safari OSX to debug my JavaScript. I'm using the Console, however, as there is a number of event handlers on the page (plus I'd like to see if the browser also fires any additional events, e.g. :hover on touch) it would very useful to see ANY/ALL events being fired in real-time. I found an article about how to do it in Firefox/FireBug.. anything like this for Safari/iPhone Simulator? Thanks!
monitorEvents
also works in Safari (iOS 11).
https://developers.google.com/web/updates/2015/05/quickly-monitor-events-from-the-console-panel
这篇关于Safari浏览器(iPhone模拟器):如何查看/监控所有被触发的事件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!