I think what you posted explains itself really.
Use .delay()
for jQuery effects including animations.
setTimeout()
is best used for everything else. For example when you need to trigger an event at a certain elapsed time.
More Related Contents:
- Delay jquery hover event?
- How to add pause between each iteration of jQuery .each()?
- jQuery delay() – how to stop it?
- TypeError: ‘undefined’ is not a function (evaluating ‘$(document)’)
- Use jQuery to change a second select list based on the first select list option
- jQuery Call to WebService returns “No Transport” error
- Custom date format with jQuery validation plugin
- jQuery event handlers always execute in order they were bound – any way around this? [duplicate]
- jQuery – Detect value change on hidden input field
- getting the X/Y coordinates of a mouse click on an image with jQuery [duplicate]
- Invoking a jQuery function after .each() has completed
- jQuery validate dynamic input array
- How to set cache: false in jQuery.get call
- linking jquery in html
- Programmatically create select list
- jQuery override default validation error message display (Css) Popup/Tooltip like
- How do I select elements on multiple attribute values
- jQuery attribute selector for multiple values
- How can I disable a button on a jQuery UI dialog?
- Detect page change on DataTable
- Fancybox: iframe doesn’t work
- Using jquery to make a POST, how to properly supply ‘data’ parameter?
- Twitter Bootstrap add active class to li
- Animate an element’s width from 0 to 100%, with it and it’s wrapper being only as wide as they need to be, without a pre-set width, in CSS3 or jQuery
- Detect change to selected date with bootstrap-datepicker
- Use jQuery to convert JSON array to HTML bulleted list
- How to get form html() via jQuery including updated value attributes?
- Async and document ready
- How to use multiple jquery object variables as selectors?
- How can I extend jQueryUI datepicker to accept an additional argument?