Created
July 3, 2014 00:40
-
-
Save rfabes21/c0cd42dd938c138edb3a to your computer and use it in GitHub Desktop.
Atom-snippets
This file contains 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
# Your snippets | |
# | |
# Atom snippets allow you to enter a simple prefix in the editor and hit tab to | |
# expand the prefix into a larger code block with templated values. | |
# | |
# You can create a new snippet in this file by typing "snip" and then hitting | |
# tab. | |
# | |
# An example CoffeeScript snippet to expand log to console.log: | |
# | |
# '.source.coffee': | |
# 'Console log': | |
# 'prefix': 'log' | |
# 'body': 'console.log $1' | |
# | |
'.source.js': | |
'backboneCollection': | |
'prefix': 'collection' | |
'body': 'define(function( require, exports, module ){\n\nvar backbone = require(\'backbone\');\nvar ${1:Model} = require(\'./models\').${1:Model};\n\nvar ${2:Collection} = backbone.Collection.extend({\n ${3://}urlRoot: \'${4:/api/v1/auction_item/}\',\n model: ${1:Model}\n});\n\nexports.${2:Collection} = ${2:Collection};\n\n});' | |
'.source.js': | |
'backboneModel': | |
'prefix': 'model' | |
'body': 'define(function( require, exports, module ){\n\nvar backbone = require(\'backbone\');\nvar ${1:Model} = backbone.Model.extend({\n defaults: {\n\n }\n});\n\nexports.${1:Model} = ${1:Model};\n\n});' | |
'.source.js': | |
'consolelog': | |
'prefix': 'console' | |
'body': 'console.log(${1:\'called\'});' | |
'.source.js': | |
'famousImageSurface': | |
'prefix': 'isurface' | |
'body': '${1:image}: {\n content: {type: \'image\', width: ${2:50}, height: ${3:50}, src: \'${4:img/foo.jpg}\'},\n properties: {\n ${6:color: \'#fff\'}\n },\n modifier: {\n origin:[0.5, 0, 0],\n opacity: 0,\n transform: Transform.translate(0, 0, 0)\n },\n}' | |
'.source.js': | |
'famousTextSurface': | |
'prefix': 'tsurface' | |
'body': '${1:text}: {\n content: {type: \'text\', text: \'${2:foo}\'},\n properties: {\n ${4:color: \'#fff\'}\n },\n modifier: {\n origin:[0.5, 0, 0],\n opacity: 0,\n transform: Transform.translate(0, 0, 0)\n },\n}' | |
'.source.js': | |
'famousView': | |
'prefix': 'famousView' | |
'body': 'define(function (require, exports, module) {\n\nvar _ = require(\'underscore\');\nvar View = require(\'rich/view\').View;\n\nvar ${1:MyView} = View.extend({\n initialize : function(){\n\n }\n});\n\nexports.${1:MyView} = ${1:MyView};\n});' | |
'.source.js': | |
'function': | |
'prefix': 'function' | |
'body': 'function(){\n ${1:}\n},' | |
'.source.js': | |
'marionetteCollectionView': | |
'prefix': 'collectionView' | |
'body': 'define(function (require, exports, module) {\n\nvar marionette = require(\'marionette\');\nvar ${2:ItemView} = require(\'./${2:ItemView}\').${2:ItemView};\n\nvar ${3:CollectionView} = marionette.CollectionView.extend({\n itemView : ${2:ItemView},\n itemViewContainer : \'#${4:item-container}\',\n initialize : function(){\n\n },\n ui : {\n\n },\n events : {\n\n }\n});\n\nexports.${3:CollectionView} = ${3:CollectionView};\n\n});' | |
'.source.js': | |
'marionetteCompositeView': | |
'prefix': 'compositeView' | |
'body': 'define(function (require, exports, module) {\n\nvar marionette = require(\'marionette\');\nvar ${2:ItemView} = require(\'./${2:ItemView}\').${2:ItemView};\nvar template = require(\'hbs!../templates/${1:template}\');\n\nvar ${3:CompositeView} = marionette.CompositeView.extend({\n template : template,\n itemView : ${2:ItemView},\n itemViewContainer : \'#${3:item-container}\',\n initialize : function(){\n\n },\n ui : {\n\n },\n events : {\n\n }\n});\n\nexports.${3:CompositeView} = ${3:CompositeView};\n\n});' | |
'.source.js': | |
'marionetteItemView': | |
'prefix': 'itemView' | |
'body': 'define(function (require, exports, module) {\n\nvar marionette = require(\'marionette\');\nvar template = require(\'hbs!../templates/${1:template}\');\n\nvar ${2:ItemView} = marionette.ItemView.extend({\n template : template,\n ui : {\n\n },\n events : {\n\n },\n initialize : function(){\n ${3:}\n }\n});\n\nexports.${2:ItemView} = ${2:ItemView};\n\n});' | |
'.source.js': | |
'marionetteRouter': | |
'prefix': 'router' | |
'body': 'define(function (require, exports, module) {\n\nvar marionette = require(\'marionette\');\n\nvar {$1:AppRouter} = marionette.AppRouter.extend({\n appRoutes:{\n \'*filter\':\'setFilter\'\n }\n});\n\nexports.{$1:AppRouter} = {$1:AppRouter};\n\n});' | |
'.text.html(.basic)': | |
'mustache': | |
'prefix': '{{' | |
'body': '{{${1:}}}' | |
'.source.python': | |
'pdb': | |
'prefix': 'pdb' | |
'body': 'import pdb; pdb.set_trace()' | |
'.source.js': | |
'require': | |
'prefix': 'require' | |
'body': 'define(function (require, exports, module) {\n \n});' | |
'.source.js': | |
'testsDescribe': | |
'prefix': 'describe' | |
'body': 'define(function(require, exports, module) {\n\n// Imports\n\n\n\ndescribe(\'${1:description here}\', function() {\n\n\n // Set Up\n\n beforeEach(function() {\n });\n\n afterEach(function() {\n });\n\n // Helpers\n\n function getOptions(augments) {\n augments = augments || {};\n\n var testSuiteDefaults = {\n };\n\n return _.extend(testSuiteDefaults, augments);\n }\n\n\n // Test Suite\n ${2:}\n \n\n}); // Eof describe\n}); // Eof define' | |
'.source.js': | |
'testsIt': | |
'prefix': 'it' | |
'body': 'it(\'${1:does this action}\', function(){\n ${2:}\n});' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
go to Atom > open your snippets:
paste snippets