Last Updated: February 25, 2016
·
450
· ndavison

Backbone.js view event targets

Functions you associate with events in Backbone.js Views are passed the event as the first parameter, meaning you can determine which element in the view raised the event by (assuming you make 'ev' the first param):

var el = ev.currentTarget;

Or you can wrap a $(ev.currentTarget)instead to create the jQuery element.