Created
August 9, 2012 12:11
-
-
Save k33g/3303698 to your computer and use it in GitHub Desktop.
Backbone model snippet for Sublime Text 2
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <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