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

Commit

Permalink
add a snippet for $timeout
Browse files Browse the repository at this point in the history
close #79
  • Loading branch information
outsideris committed Jan 6, 2018
1 parent b9b935d commit 4b3197d
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 5 deletions.
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,13 @@ $scope.$watch('$1', function(newValue, oldValue) {
});
```

#### ngto
```
$timeout(function() {
$2
}, $1)
```

##### ngc
```
var $1 = function($scope, $2) {
Expand Down
17 changes: 12 additions & 5 deletions snippets/js-templates.cson
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,13 @@
$2
})
"""
"$timeout":
"prefix": "ngto"
"body": """
$timeout(function() {
$2
}, $1)
"""
"controller":
"prefix": "ngc"
"body": """
Expand Down Expand Up @@ -181,11 +188,11 @@
"body": """
$http({method: '${1:GET}', url: '$2'})
.then(function successCallback(data, status, headers, config) {
$3
},
function errorCallback(data, status, headers, config) {
$4
});
$3
},
function errorCallback(data, status, headers, config) {
$4
});
"""
"copy":
"prefix": "ngcopy"
Expand Down

0 comments on commit 4b3197d

Please sign in to comment.