Skip to content

Instantly share code, notes, and snippets.

@collin
Created December 14, 2015 22:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save collin/21ae59b0f776fdf9c950 to your computer and use it in GitHub Desktop.
Save collin/21ae59b0f776fdf9c950 to your computer and use it in GitHub Desktop.
function Thing () {
this.method = this.method.bind(this);
$(element).on('event', this.method);
}
Thing.prototype.method = function () {
}
function Thing () {
$(element).on('event', this.method.bind(this));
}
Thing.prototype.method = function () {
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment