Easy Tutorial
❮ Event Keypress Sel Attribute Contains Value ❯

jQuery jQuery.fx.interval Property

jQuery Properties

Example

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; 
});

Definition and Usage

The jQuery.fx.interval property is used to change the animation run rate in milliseconds.

The default value is 13 milliseconds. This property is often used to modify the number of frames per second at which animations run. Lowering this value can make animations run more smoothly in faster browsers, but it can affect performance and CPU usage.

Note: Since jQuery uses a global interval time, for this property to take effect, animations should not be running or all animations should be stopped first.

Note: This property is ineffective in browsers that support the requestAnimationFrame property, such as Google Chrome 11.


Syntax

Parameter Description
milliseconds Required. Specifies the animation run rate in milliseconds. The default is 13 milliseconds.

jQuery Properties

❮ Event Keypress Sel Attribute Contains Value ❯