Skip to content

Instantly share code, notes, and snippets.

@nelyj
Created February 11, 2015 22:47
Show Gist options
  • Save nelyj/7649bd759ee3e888cccf to your computer and use it in GitHub Desktop.
Save nelyj/7649bd759ee3e888cccf to your computer and use it in GitHub Desktop.
place.js
exports.definition = {
config: {
"URL": "http://192.168.0.15:3000/v/places",
// "debug": 1,
"adapter": {
"type": "restapi",
"collection_name": "Place",
"idAttribute": "id"
},
"headers": { // your custom headers
"Content-Type": "application/json"
// "Accept": "application/vnd.stackmob+json; version=0",
// "X-StackMob-API-Key": "your-stackmob-key"
},
"parentNode": "" //your root node
},
extendModel: function(Model) {
_.extend(Model.prototype, {});
return Model;
},
extendCollection: function(Collection) {
_.extend(Collection.prototype, {});
return Collection;
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment