A
A
Anna Bakurova2015-09-17 12:26:05
JavaScript
Anna Bakurova, 2015-09-17 12:26:05

How to get the element on which the event was fired in the backbone?

App.Views.Login = Backbone.View.extend({

  render: function() {
  },

  events: {
    'click .btn-next': 'amination',
  },

  amination: function() {
  },
});

How to get the element on which the click was called in the animation function ( .btn-next of course several)
this refers to the view itself

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dmitry Kravchenko, 2015-09-17
@Libris

amination: function(e){
  var target = e.target;
}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question