YouTip LogoYouTip

Misc Jquery Speed

# jQuery jQuery.speed Method [![Image 3: jQuery Misc Methods](#)jQuery Misc Methods](#) * * * ## Definition and Usage The $.speed() function creates an object containing a set of properties to define custom animations. **Note:** 1. The $.speed() method provides a way to define properties such as duration, easing, and queue for custom animations. Using it, you don't have to implement the logic involved in default values and optional parameters yourself. * * * ## Syntax Method 1 _$_.speed( [, settings ] ) | Parameter | Description | | :--- | :--- | | _duration(default:400)_ | Number / String A string or number determining how long the animation will run. (Three preset speed strings ("slow", "normal", or "fast") or a millisecond value representing the animation duration (e.g., 1000)) | | _settings_ | PlainObject type * **easing** String A string indicating which easing function to use. * **complete** Function() A function to call when the animation completes. | Method 2 _$_.speed( [, easing ] [, complete ] ) | Parameter | Description | | :--- | :--- | | _duration(default:400)_ | Number / String A string or number determining how long the animation will run. (Three preset speed strings ("slow", "normal", or "fast") or a millisecond value representing the animation duration (e.g., 1000)) | | _easing_ | String A string indicating which easing function to use. | | _complete_ | Function() A function to call when the animation completes, called once for each matched element. | Method 3 _$_.speed( settings ) | Parameter | Description | | :--- | :--- | | _settings_ | PlainObject type * **duration** Number / String A string or number determining how long the animation will run. * **easing** String A string indicating which easing function to use. * **complete** Function() A function to call when the animation completes. | * * jQuery Misc Methods](#)
← Html EscapeselectorMisc Deferred Then β†’