jQuery jQuery.fx.intervalProperty
Examples
Run the animation of the <div> element with fewer frames:
$("#toggle").on("click",function(){
$("div").toggle(5000);
});
$("#interval").on("click",function(){
jQuery.fx.interval = 500;
});
Try it »
Definition and Usage
The jQuery.fx.interval property is used to change the animation running rate in milliseconds.
The default value is 13 milliseconds. This property is often used to modify the number of frames per second of an animation. Lowering this value can make animations run more smoothly in faster browsers, but doing so will affect performance and CPU.
Note:Since jQuery uses a global interval time, for this property to take effect, animations should not be running, or you should stop all animations first.
Note:This property is ineffective in browsers that support the requestAnimationFrame property, such as Google Chrome 11.
Syntax
jQuery.fx.interval = milliseconds;
| Parameter | Description |
|---|---|
| milliseconds | Required. Specifies the animation running rate in milliseconds. The default is 13 milliseconds. |
Other Extensions
jQuery Properties