@@ -15,15 +15,15 @@ $(function () {
15
15
} ) ;
16
16
17
17
$ ( function ( ) {
18
- var timer = new Timer ( ) ;
18
+ const timer = new Timer ( ) ;
19
19
timer . start ( ) ;
20
20
timer . addEventListener ( 'secondsUpdated' , function ( e ) {
21
21
$ ( '#basicUsage' ) . html ( timer . getTimeValues ( ) . toString ( ) ) ;
22
22
} ) ;
23
23
} ) ;
24
24
25
25
$ ( function ( ) {
26
- var timer = new Timer ( ) ;
26
+ const timer = new Timer ( ) ;
27
27
timer . start ( { precision : 'seconds' } ) ;
28
28
timer . addEventListener ( 'secondsUpdated' , function ( e ) {
29
29
$ ( '#gettingValuesExample .days' ) . html ( timer . getTimeValues ( ) . days ) ;
@@ -41,7 +41,7 @@ $(function () {
41
41
} ) ;
42
42
43
43
$ ( function ( ) {
44
- var timer = new Timer ( ) ;
44
+ const timer = new Timer ( ) ;
45
45
46
46
$ ( '#chronoExample .startButton' ) . click ( function ( ) {
47
47
timer . start ( ) ;
@@ -73,7 +73,7 @@ $(function () {
73
73
} ) ;
74
74
75
75
$ ( function ( ) {
76
- var timer = new Timer ( ) ;
76
+ const timer = new Timer ( ) ;
77
77
timer . start ( { precision : 'seconds' , startValues : { seconds : 90 } , target : { seconds : 120 } } ) ;
78
78
$ ( '#startValuesAndTargetExample .values' ) . html ( timer . getTimeValues ( ) . toString ( ) ) ;
79
79
timer . addEventListener ( 'secondsUpdated' , function ( e ) {
@@ -86,7 +86,7 @@ $(function () {
86
86
} ) ;
87
87
88
88
$ ( function ( ) {
89
- var timer = new Timer ( ) ;
89
+ const timer = new Timer ( ) ;
90
90
timer . start ( { countdown : true , startValues : { seconds : 30 } } ) ;
91
91
$ ( '#countdownExample .values' ) . html ( timer . getTimeValues ( ) . toString ( ) ) ;
92
92
timer . addEventListener ( 'secondsUpdated' , function ( e ) {
@@ -98,7 +98,7 @@ $(function () {
98
98
} ) ;
99
99
100
100
$ ( function ( ) {
101
- var timer = new Timer ( ) ;
101
+ const timer = new Timer ( ) ;
102
102
timer . start ( {
103
103
callback : function ( timer ) {
104
104
$ ( '#callbackExample .values' ) . html (
@@ -109,15 +109,15 @@ $(function () {
109
109
} ) ;
110
110
111
111
$ ( function ( ) {
112
- var timer = new Timer ( ) ;
112
+ const timer = new Timer ( ) ;
113
113
timer . start ( { precision : 'secondTenths' } ) ;
114
114
timer . addEventListener ( 'secondTenthsUpdated' , function ( e ) {
115
115
$ ( '#secondTenthsExample .values' ) . html ( timer . getTimeValues ( ) . toString ( [ 'hours' , 'minutes' , 'seconds' , 'secondTenths' ] ) ) ;
116
116
} ) ;
117
117
} ) ;
118
118
119
119
$ ( function ( ) {
120
- var timer = new Timer ( { countdown : true , startValues : { seconds : 5 } } ) ;
120
+ const timer = new Timer ( { countdown : true , startValues : { seconds : 5 } } ) ;
121
121
122
122
timer . start ( { startValues : { seconds : 30 } , target : { seconds : 10 } } ) ;
123
123
$ ( '#defaultParamsExample .values' ) . html ( timer . getTimeValues ( ) . toString ( ) ) ;
0 commit comments