Feed Sign in with OpenID OpenID

Simon Willison’s Weblog

Visual Event. External code loading bookmarklet that visualises the JavaScript events hooked up to the current page, and lets you view the source code of the event handling function for each one. Only works for events added by jQuery, YUI or MooTools since those libraries maintain a cache of event handlers that they add, to work around the standard DOM’s omission of handler introspection.

Tagged , , , , , , , ,

3 comments

  1. Hi Simon, think that URL should be http://www.sprymedia.co.uk/article/Visual+Event - your comments thing seems to escape the "+".

    Simon Scarfe - 10th December 2008 16:25 - #

  2. Prototype does this as well.

    All eventlisteners are on Event.cache and each element has an array of integers on _prototypeEventID, which are the index under which that element's eventlisteners are.

    André Luís - 13th December 2008 02:04 - #

  3. Hi all,

    Thanks for the post about Visual Event Simon! To let you know, I've just added Prototype support as a result of André's comment and an e-mail I received from John Schulz. So thank you very much to both!

    Since it's a bookmarklet - everyone will get the latest version when you load it up on a page the next time. :-)

    Allan

    Allan Jardine - 10th January 2009 08:58 - #

Sign in with OpenID

Auto-HTML: Line breaks are preserved; URLs will be converted in to links.

Manual XHTML: Enter your own, valid XHTML. Allowed tags are a, p, blockquote, ul, ol, li, dl, dt, dd, em, strong, dfn, code, q, samp, kbd, var, cite, abbr, acronym, sub, sup, br, pre

A django site