Answer the question
In order to leave comments, you need to log in
Why doesn't this simple Backbone code work?
var Change = Backbone.Model.extend({
events: {
"click #btn_change": "check"
},
check: function () {
console.log(1);
}
});
var start = new Change();
Answer the question
In order to leave comments, you need to log in
I agree with Ivan, you need to use View instead of Model, since the methods that are described in your code are available only for View.
You also need to specify a template
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question