Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

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 FabienArcellier/5652977 to your computer and use it in GitHub Desktop.
Save FabienArcellier/5652977 to your computer and use it in GitHub Desktop.
Override fetch method from a backbone collection Reference : http://stackoverflow.com/questions/13358477/override-backbones-collection-fetch
var MyCollection = Backbone.Collection.extend({
//custom methods
fetch: function(options) {
//do specific pre-processing
//Call Backbone's fetch
return Backbone.Collection.prototype.fetch.call(this, options);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment