Skip to content

Instantly share code, notes, and snippets.

@kirkonrails
Created April 9, 2014 13:20
Show Gist options
  • Save kirkonrails/10269631 to your computer and use it in GitHub Desktop.
Save kirkonrails/10269631 to your computer and use it in GitHub Desktop.
Log all jQuery events to console via redfine jquery trigger
var oldJQueryEventTrigger = jQuery.event.trigger;
jQuery.event.trigger = function( event, data, elem, onlyHandlers ) {
console.log( event, data, elem, onlyHandlers );
oldJQueryEventTrigger( event, data, elem, onlyHandlers );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment