记录或记录所有浏览器DOM / JQuery事件 [英] Record or log all browser DOM/JQuery Event(s)

查看:167
本文介绍了记录或记录所有浏览器DOM / JQuery事件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个问题,需要在一些浏览器事件(点击,焦点,?)触发后以编程方式(在javascript中)执行第三方组件中发生的某些事情。我不知道事件类型,事件绑定的元素或正确的参数。

I had a problem of needing to do some stuff programmatically (in javascript) that was happening in a third party component after being triggered by some browser events (click, focus, ?). I didn't know the event type, the element that the event was bound to, or the proper parameters.

- 尝试在子树修改上设置Chrome断点,但没有任何效果。

- 检查jQuery事件,但数据('事件')没有不要透露任何有用的东西 - 他们必须使用DOM事件。

-Tried setting Chrome breakpoints on subtree modifications, but nothing worked.
-Tried checking for jQuery events, but data('events') didn't reveal anything useful- they must be using DOM events.

不应该有一些记录/捕获/记录浏览器中所有事件的方法,然后检查他们(甚至打他们回来)?这似乎是找出我想要找到的唯一方法。

Shouldn't there be some way of recording/capturing/logging all the events in a browser and then checking them (or even playing them back)? That seems like the only way to find out what I want to find out.

推荐答案

是Chrome可以:)

Yes Chrome can :)


  1. 从扳手菜单中打开开发工具(Ctrl + Shift + I)/ /,或右键单击页面,然后单击检查元素

  2. 转到时间轴选项卡。

  3. 点击底部的一点录制按钮。

  4. 刷新页面。

  1. Open your the "Developer Tools" (Ctrl+Shift+I) / from the Wrench menu / or right-click on page and click "Inspect Element"
  2. Go to the "Timeline" tab.
  3. Click the little Record button at the bottom.
  4. Refresh the page.

它将显示所有加载事件(黄色)以及当您鼠标悬停时发生的AJAX事件东西等。

It will show you all load events (in yellow) as well as AJAX events that happen when you mouse-over stuff, etc.

干杯;)

这篇关于记录或记录所有浏览器DOM / JQuery事件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆