Skip to content

Commit f1106da

Browse files
author
Alex Shnayder
committed
issue 434 - fix CRLF issues which caused extra lines in file
1 parent f4c34dd commit f1106da

File tree

1 file changed

+7
-24
lines changed

1 file changed

+7
-24
lines changed

docs/timeout-service.md

Lines changed: 7 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -2,61 +2,44 @@
22

33
# timeout-service - use `$timeout` instead of `setTimeout`
44

5-
6-
75
Instead of the default setTimeout function, you should use the AngularJS wrapper service $timeout
86
*
97

10-
118
**Rule based on Angular 1.x**
129

13-
14-
1510
**Styleguide Reference**
1611

1712
* [y181 by johnpapa - Angular $ Wrapper Services - $timeout and $interval](https://github.com/johnpapa/angular-styleguide/blob/master/a1/README.md#style-y181)
1813

19-
2014
## Examples
2115

22-
23-
2416
The following patterns are considered problems;
2517

2618
/*eslint angular/timeout-service: 2*/
27-
28-
// invalid
19+
20+
// invalid
2921
setTimeout(function() {
3022
// ...
3123
}, 1000) // error: You should use the $timeout service instead of the default window.setTimeout method
32-
3324

34-
// invalid
25+
// invalid
3526
window.setTimeout(function() {
3627
// ...
3728
}, 1000) // error: You should use the $timeout service instead of the default window.setTimeout method
3829

39-
4030
// invalid
4131
$window.setTimeout(function() {
4232
// ...
43-
}, 1000) // error: You should use the $timeout service instead of the default window.setTimeout method
44-
45-
46-
33+
}, 1000) // error: You should use the $timeout service instead of the default window.setTimeout method
4734

4835
The following patterns are **not** considered problems;
4936

5037
/*eslint angular/timeout-service: 2*/
51-
52-
// valid
38+
39+
// valid
5340
$timeout(function() {
5441
// ...
55-
}, 1000)
56-
57-
58-
59-
42+
}, 1000)
6043

6144
## Version
6245

0 commit comments

Comments
 (0)