Pass event data as arguments to the handler. #183

wants to merge 1 commit into


None yet

2 participants


Mimic jQuery's custom event triggering syntax -

Allows you to write:

$('#foo').bind('custom', function(event, param1, param2) {
  alert(param1 + "\n" + param2);
$('#foo').trigger('custom', ['Custom', 'Event']);

Rather than:

$('#foo').bind('custom', function(event, params) {
  alert(params[0] + "\n" + params[1]);
$('#foo').trigger('custom', ['Custom', 'Event']);
@mislav mislav added a commit that closed this pull request Aug 1, 2011
@johnboxall johnboxall event handlers now receive custom data in multiple arguments
For jQuery compatibility.

closes #183
@mislav mislav closed this in 11de4dc Aug 1, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment