What are deferred and promise object in jQuery?

devquora
devquora

Posted On: Feb 22, 2018

 

The deferred object in jQuery is used to create a promise. After creating a promise, jQuery changes its state to resolved or rejected. Deferred is used to provide a promise to the calling code in your own function.

The promise is set on a deferred object that will be executed when the deferred collection is complete. The state of the promise cannot be changed. The deferred object is used to create a promise.

    Related Questions

    Please Login or Register to leave a response.

    Related Questions

    JQuery Interview Questions

    What is jQuery?

    jQuery is a lightweight JavaScript library which gives a quick and simple method for HTML DOM traversing and manipulati..

    JQuery Interview Questions

    What are the advantages of JQuery ?

    There are many advantages of JQuery. Some of them are :It is more like a JavaScript enhancement so there is no overhea..

    JQuery Interview Questions

    What are the different type of selectors in Jquery?

    There are 3 types of selectors in JqueryCSS Selector XPath Selector Custom Selector..