Skip to content
This repository was archived by the owner on Sep 8, 2020. It is now read-only.

Commit 71235e2

Browse files
author
Dean Sofer
committed
Initial conversion of textmate version
0 parents  commit 71235e2

File tree

3 files changed

+210
-0
lines changed

3 files changed

+210
-0
lines changed

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# angularjs package
2+
3+
A short description of your package.

package.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"name": "angularjs",
3+
"version": "0.0.1",
4+
"private": true,
5+
"description": "An AngularJS package for Atom",
6+
"repository": "https://github.com/angular-ui/AngularJS-Atom",
7+
"license": "MIT",
8+
"engines": {
9+
"atom": ">0.50.0"
10+
},
11+
"dependencies": {
12+
}
13+
}

snippets/angularjs.cson

Lines changed: 194 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,194 @@
1+
'.source.js, .source.coffee':
2+
'$apply':
3+
'prefix': '.$'
4+
'body': '.\\$apply($0)$TM_JAVASCRIPT_TERMINATOR'
5+
'$broadcast':
6+
'prefix': '.$'
7+
'body': '.\\$broadcast(\'${1:name}\', ${2:arguments})$TM_JAVASCRIPT_TERMINATOR'
8+
'$destroy':
9+
'prefix': '.$'
10+
'body': '.\\$destroy()$TM_JAVASCRIPT_TERMINATOR'
11+
'$digest':
12+
'prefix': '.$'
13+
'body': '.\\$digest()$TM_JAVASCRIPT_TERMINATOR'
14+
'$emit':
15+
'prefix': '.$'
16+
'body': '.\\$emit(\'${1:name}\', ${2:arguments})$TM_JAVASCRIPT_TERMINATOR'
17+
'$eval':
18+
'prefix': '.$'
19+
'body': '.\\$eval($0)$TM_JAVASCRIPT_TERMINATOR'
20+
'$evalAsync':
21+
'prefix': '.$'
22+
'body': '.\\$evalAsync($0)$TM_JAVASCRIPT_TERMINATOR'
23+
'$new':
24+
'prefix': '.$'
25+
'body': '.\\$new(${1:isolate})$TM_JAVASCRIPT_TERMINATOR'
26+
'$on':
27+
'prefix': '.$'
28+
'body': '.\\$on(\'${1:name}\', ${2:function(){$3}})$TM_JAVASCRIPT_TERMINATOR'
29+
'$parent':
30+
'prefix': '.$'
31+
'body': '.\\$parent.'
32+
'$root':
33+
'prefix': '.$'
34+
'body': '.\\$root.'
35+
'$watch':
36+
'prefix': '.$'
37+
'body': '.\\$watch(\'${1:name}\', function(scope, newValue, oldValue) {\n\t$0\n})$TM_JAVASCRIPT_TERMINATOR'
38+
'$http':
39+
'prefix': 'http'
40+
'body': '\\$http(\'${1:GET|POST|PUT|DELETE}\', ${2:url}${3:, ${4:post}}, ${5:function(status, response){\n\t${6:// success}\n}}${7:, function(status, response){\n\t${8:// error}\n}})$TM_JAVASCRIPT_TERMINATOR'
41+
'copy':
42+
'prefix': 'copy'
43+
'body': 'angular.copy(${1:source}${2:, ${3:destination}})'
44+
'directive':
45+
'prefix': 'dir'
46+
'body': 'directive(\'$1\', [${3:\'$4\', }function($4){\n\t${5:// Runs during compile}\n\treturn {\n\t\t// name: \'\',\n\t\t// priority: 1,\n\t\t// terminal: true,\n\t\t// scope: {}, // {} = isolate, true = child, false/undefined = no change\n\t\t// cont­rol­ler: function(\\$scope, \\$element, \\$attrs, \\$transclue) {},\n\t\t// require: \'ngModel\', // Array = multiple requires, ? = optional, ^ = check parent elements\n\t\t// restrict: \'A\', // E = Element, A = Attribute, C = Class, M = Comment\n\t\t// template: \'\',\n\t\t// templateUrl: \'\',\n\t\t// replace: true,\n\t\t// transclude: true,\n\t\t// compile: function(tElement, tAttrs, function transclude(function(scope, cloneLinkingFn){ return function linking(scope, elm, attrs){}})),\n\t\tlink: function(\\$scope, iElm, iAttrs, controller) {\n\t\t\t$0\n\t\t}\n\t};\n}])$TM_JAVASCRIPT_TERMINATOR'
47+
'element':
48+
'prefix': 'el'
49+
'body': 'angular.element(${1:element})$TM_JAVASCRIPT_TERMINATOR'
50+
'equals':
51+
'prefix': 'eq'
52+
'body': 'angular.equals(${1:object1}, ${2:object2})$TM_JAVASCRIPT_TERMINATOR'
53+
'extend':
54+
'prefix': 'extend'
55+
'body': 'angular.extend(${1:destinationObject}, ${2:sourceObject})'
56+
'$filter':
57+
'prefix': 'filter'
58+
'body': '\\$filter(\'${1:currency|date|filter|json|limitTo|linky|lowercase|number|orderBy|uppercase}\')(${2:array}${3:, ${4:expression}})$TM_JAVASCRIPT_TERMINATOR'
59+
'forEach':
60+
'prefix': 'each'
61+
'body': 'angular.forEach(${1:values}, function(${2:value}, ${3:key}){\n\t$0\n})$TM_JAVASCRIPT_TERMINATOR'
62+
'isArray':
63+
'prefix': 'is'
64+
'body': 'angular.isArray(${1:value})'
65+
'isDefined':
66+
'prefix': 'is'
67+
'body': 'angular.isDefined(${1:value})'
68+
'isFunction':
69+
'prefix': 'is'
70+
'body': 'angular.isFunction(${1:value})'
71+
'isNumber':
72+
'prefix': 'is'
73+
'body': 'angular.isNumber(${1:value})'
74+
'isObject':
75+
'prefix': 'is'
76+
'body': 'angular.isObject(${1:value})'
77+
'isString':
78+
'prefix': 'is'
79+
'body': 'angular.isString(${1:value})'
80+
'lowercase':
81+
'prefix': 'lower'
82+
'body': 'angular.lowercase(${1:string})$TM_JAVASCRIPT_TERMINATOR'
83+
'module':
84+
'prefix': 'mod'
85+
'body': '/**\n * $1 Module\n *\n * ${2:Description}\n */\nangular.module(\'$1\', [$3]).$0'
86+
'noop':
87+
'prefix': 'noop'
88+
'body': 'angular.noop'
89+
'uppercase':
90+
'prefix': 'upper'
91+
'body': 'angular.uppercase(${1:string})$TM_JAVASCRIPT_TERMINATOR'
92+
'.js':
93+
'$routeProvider.when':
94+
'prefix': 'route'
95+
'body': '\\$routeProvider.when(\'$1\', {template: \'$2\', controller: $3})$TM_JAVASCRIPT_TERMINATOR'
96+
'.text.html':
97+
'|currency':
98+
'prefix': '|'
99+
'body': '|currency${1::\'${2:symbol}\'}'
100+
'|date':
101+
'prefix': '|'
102+
'body': '|date${1::\'${2:format}\'}'
103+
'|filter':
104+
'prefix': '|'
105+
'body': '|filter:${1:expression}'
106+
'|json':
107+
'prefix': '|'
108+
'body': '|json'
109+
'|limitTo':
110+
'prefix': '|'
111+
'body': '|limitTo:${1:limit}'
112+
'|lowercase':
113+
'prefix': '|'
114+
'body': '|lowercase'
115+
'|number':
116+
'prefix': '|'
117+
'body': '|number${1:${2:fractionSize}}'
118+
'|orderBy':
119+
'prefix': '|'
120+
'body': '|orderBy:${1:fractionSize}${2::${3:reverse}}'
121+
'|uppercase':
122+
'prefix': '|'
123+
'body': '|uppercase'
124+
'.text.html .meta.tag':
125+
'ngRepeat':
126+
'prefix': 'repeat'
127+
'body': 'ng-repeat="${1:(${2:key}, ${3:value})} in ${4:dataset}"'
128+
'ngSwitch':
129+
'prefix': 'switch'
130+
'body': 'ng-switch-when="$1"'
131+
'ngSwitchDefault':
132+
'prefix': 'default'
133+
'body': 'ng-switch-default'
134+
'ngSwitchWhen':
135+
'prefix': 'when'
136+
'body': 'ng-switch-when="$0"'
137+
'ngBindHtmlUnsafe':
138+
'prefix': 'html'
139+
'body': 'ng-bind-html-unsafe="$0"'
140+
'ngBindTemplate':
141+
'prefix': 'tmpl'
142+
'body': 'ng-bind-template="$0"'
143+
'ngChecked':
144+
'prefix': 'check'
145+
'body': 'ng-checked="$0"'
146+
'ngClass':
147+
'prefix': 'class'
148+
'body': 'ng-class="$0"'
149+
'ngClick':
150+
'prefix': 'click'
151+
'body': 'ng-click="$0"'
152+
'ngController':
153+
'prefix': 'ctrl'
154+
'body': 'ng-controller="$0"'
155+
'ngDisabled':
156+
'prefix': 'disabled'
157+
'body': 'ng-disabled="{{$0}}"'
158+
'ngHide':
159+
'prefix': 'hide'
160+
'body': 'ng-hide="$0"'
161+
'ngNonBindable':
162+
'prefix': 'non'
163+
'body': 'ng-non-bindable="$0"'
164+
'ngOptions':
165+
'prefix': 'options'
166+
'body': 'ng-options="${1:select} as ${2:label} for ${3:value} in ${4:array}"'
167+
'ngReadonly':
168+
'prefix': 'readonly'
169+
'body': 'ng-readonly="$0"'
170+
'ngSelected':
171+
'prefix': 'selected'
172+
'body': 'ng-selected="$0"'
173+
'ngShow':
174+
'prefix': 'show'
175+
'body': 'ng-show="$0"'
176+
'ngStyle':
177+
'prefix': 'style'
178+
'body': 'ng-style="$0"'
179+
'.text.html:not(.meta.tag)':
180+
'ngInclude':
181+
'prefix': 'inc'
182+
'body': '<ng-include src="$1"${2: scope="$3"}${4: onload="$5"}></ng-include>'
183+
'ngPluralize':
184+
'prefix': 'plural'
185+
'body': '<ng-pluralize count="$1" when="$2"${3: offset="$4"}></ng-pluralize>'
186+
'ngSwitch':
187+
'prefix': 'switch'
188+
'body': '<ng-switch on="$1">$0</ng-switch>'
189+
'script template':
190+
'prefix': 'tmpl'
191+
'body': '<script type="text/ng-template">$0</script>'
192+
'ngView':
193+
'prefix': 'view'
194+
'body': '<ng-view></ng-view>'

0 commit comments

Comments
 (0)