How to abort an AJAX request in jQuery 3.0?
this.r = $.ajax();
The promise does not have a abort method like in older jQuery versions
if(this.r && this.r.state() == 'pending')
{
this.r.abort(); <- error not working
}
How to abort an AJAX request in jQuery 3.0?
this.r = $.ajax();
The promise does not have a abort method like in older jQuery versions
if(this.r && this.r.state() == 'pending')
{
this.r.abort(); <- error not working
}
In jQuery 3.0, jQuery.Deferred is Promises/A+ compatible. The cancellation spec is still under development, so at this time it's not possible to abort an AJAX request.
Also see Status of cancellable promises for some background information regarding the spec.