Easy Tutorial
❮ Jq Sel Empty Misc Iswindow ❯

jQuery deferred.rejectWith() Method

jQuery Miscellaneous Methods


Definition and Usage

The deferred.rejectWith() function is used to reject a deferred object and invoke any failCallbacks with the given context and args.

Note: 1. Typically, only the creator of the deferred object can call this method. You can prevent other code from changing the state of the deferred object or reporting its status by returning a restricted Promise object with deferred.promise().


Syntax

Parameter Description
context Object type Passed as the this object to the failCallbacks
args Array type Passes an optional array of arguments to the failCallbacks

jQuery Miscellaneous Methods

❮ Jq Sel Empty Misc Iswindow ❯