Reputation: 1739
I did try the following in my initialise
function in Backbone.View
this.model.bind('change', this.render, this);
this.model.on('change', this.render, this);
Apparently they work the same way.
Are this method equivalent.
Which one should I prefer?
Upvotes: 3
Views: 858
Reputation: 243
Yes, they are equivalent. However, bind (and unbind) are only kept for backwards compability. You should use on.
Hope this helps!
Upvotes: 6