Skip to content

Instantly share code, notes, and snippets.

@k33g
Created August 9, 2012 12:11
Show Gist options
  • Select an option

  • Save k33g/3303698 to your computer and use it in GitHub Desktop.

Select an option

Save k33g/3303698 to your computer and use it in GitHub Desktop.
Backbone model snippet for Sublime Text 2
<snippet>
<content><![CDATA[
//${1:model_name}
window.${1:model_name} = Backbone.Model.extend({//instance members
url : "",
idAttribute : "_id",
initialize : function () {
},
default : function () {
}
},{//class members
});
window.${1:model_name}Collection = Backbone.Collection.extend({//instance members
model : ${1:model_name},
url : "",
},{//class members
});
]]></content>
<tabTrigger>bbmodel</tabTrigger>
</snippet>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment