问题
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!
回答1:
monitorEvents
also works in Safari (iOS 11).
https://developers.google.com/web/updates/2015/05/quickly-monitor-events-from-the-console-panel
来源:https://stackoverflow.com/questions/20713106/safari-browser-iphone-simulator-how-to-see-monitor-all-events-being-triggered