This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Backbone.Notifications = {}; | |
_.extend(Backbone.Notifications, Backbone.Events); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var FirstView = Backbone.View.extend({ | |
initialize: function() { | |
Backbone.Notifications.on('SomeViewRendered', function (msg) { | |
alert(msg); | |
}, this); | |
} | |
}); | |
var SecondView = Backbone.View.extend({ | |
render: function() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (void)rulesAreForDouches { | |
if (!goodStuff) { | |
return; | |
} | |
if (badStuff) { | |
return; | |
} | |
[self doGood]; | |
} |
NewerOlder