Skip to content

Instantly share code, notes, and snippets.

@rohn
Created December 17, 2012 19:08
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 rohn/4320987 to your computer and use it in GitHub Desktop.
Save rohn/4320987 to your computer and use it in GitHub Desktop.
Backbone: model
define(function(require) {
"use strict";
var Backbone = require("backbone");
var model = Backbone.Model.extend({
initialize: {
// initialization
},
defaults: {
// key: "value"
},
validate: function(attrs) {
//validations
}
});
return model;
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment