Created
March 29, 2014 06:19
-
-
Save vinitkumar/9849510 to your computer and use it in GitHub Desktop.
This file contains 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
proy.on("all", function (eventName) { | |
object.trigger(eventName); | |
}); | |
book.on({ | |
"change:title": titleView.update, | |
"change:author": authorPane.update, | |
"destroy": bookView.remove | |
}); | |
// off object.off([event], ['callback', ['context']) | |
// | |
// remove just the 'onChange' callback | |
// | |
object.off("change", onChange); | |
// remove all change callbacks | |
object.off("change"); | |
// Remove the `onchange` callbacks for all events | |
object.off(null, null, context); | |
// remoe all callbacks on '`object`' | |
object.off(); | |
// listenTo | |
// | |
// tell an object to listen to a particular event. | |
view.listenTo(model, 'change', view.render); | |
view.stopListening(); | |
view.stopListening(model); | |
view.listenToOnce(model, 'change', view.render); | |
add, remove, reset, sort, change, change:[attribute] | |
destroy, request, sync, error, invalid, route:[name] | |
route, all |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment