You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There's several different versions of the file, but you only need one.
14
+
15
+
* In case you want to develop against the Runner, you can pick the non-minified version `jquery.runner.js`.
16
+
* If you want to deploy Runner with your site/app, pick either `jquery.runner-min.js`.
17
+
* Or if you develop with CoffeeScript and really want to know what's happening there, grab the `jquery.runner.coffee`. (Disclaimer: no support provided for the CoffeeScript file. If you don't know what it is, don't use it.)
18
+
7
19
Include script *after* the jQuery library:
8
20
9
21
```html
@@ -128,8 +140,6 @@ You can alter the behavior by passing options object to the initialization.
128
140
129
141
*`format` - (function) A custom format function to replace the default time formatting. By default this is not set. Takes in two arguments: first one is the current time value in milliseconds, second one is the settings object. This function should return a string or a number.
130
142
131
-
*`interval` - (integer) Time in milliseconds how often we update the current time. Defaults to 20ms. **Note that if you use the `stopAt` option, the accuracy of the stop time will be affected by this. Also note that it is not recommended to use this option, unless you know what you're doing.**
132
-
133
143
134
144
## Events
135
145
@@ -176,12 +186,9 @@ $('#runner').runner({
176
186
countdown:true,
177
187
startAt:30000,
178
188
milliseconds:false,
179
-
interval:1000
180
189
});
181
190
```
182
191
183
-
*Note that the `interval` option is only set to demonstrate the possibility to change this value. In this example, it is not really needed to alter the interval, however, if you have dozens of runners like this on one page, it might be wise to make the update interval a bit slower so that it won't eat up all the CPU.*
184
-
185
192
186
193
#### Initialize a normal count up runner with a custom formatter function that displays the time in minutes (with decimals):
187
194
@@ -207,6 +214,12 @@ $('#runner').runner({
207
214
208
215
## Changelog
209
216
217
+
### v2.3.0 - *2013-07-14* - Improvements and fixes
218
+
* Runner now utilizes requestAnimationFrame if applicable and falls back to setTimeout
219
+
* Fixed a small bug with dependency checks
220
+
* Removed ability to tweak the runner interval due to requestAnimationFrame change
221
+
* Now also serving a gzipped version of the minified runner code in build folder, only 1.6KB!
222
+
210
223
### v2.2.0 - *2013-05-24* - Feature improvements and fixes
211
224
* Fixed a couple of small underlying bugs
212
225
* The first lap-time value now takes under consideration if the startAt time was something else than 0
0 commit comments