mirror of
https://github.com/jashkenas/backbone.git
synced 2026-04-30 03:00:06 -04:00
fixes #244 -- allow View#events to be defined as a function, making it easier to call super.
This commit is contained in:
@@ -118,8 +118,8 @@ $(document).ready(function() {
|
||||
var count = 0;
|
||||
var ViewClass = Backbone.View.extend({
|
||||
el: $('body'),
|
||||
events: {
|
||||
"fake$event.namespaced": "run"
|
||||
events: function() {
|
||||
return {"fake$event.namespaced": "run"};
|
||||
},
|
||||
run: function() {
|
||||
count++;
|
||||
|
||||
Reference in New Issue
Block a user