Deprecation of .success(), .error() and .complete() in jQuery > 1.8

557 views
Skip to first unread message

Bernhard Rode

unread,
Apr 26, 2013, 8:33:23 AM4/26/13
to ang...@googlegroups.com
Today I 've found a deprecation notice on the jQuery API documentation page:

http://api.jquery.com/jQuery.get/

Deprecation Notice
The jqXHR.success()jqXHR.error(), and jqXHR.complete() callback methods introduced in jQuery 1.5 aredeprecated as of jQuery 1.8. To prepare your code for their eventual removal, use jqXHR.done()jqXHR.fail(), andjqXHR.always() instead.

As I'm working on a big Angular.JS project, based heavily on .success() callbacks. So I wonder if the parts of jQuery used in Angular.JS willbe affected by this dramatic change. Or if the Angular.JS API for $http.get will change in the future?

César González

unread,
Apr 28, 2013, 2:23:38 AM4/28/13
to ang...@googlegroups.com
I think that no problem. Angular is using jqLite a tiny subset of jQuery that allows Angular to manipulate the DOM and into the http.js from source I don't see references to these to make ajaxs calls. The succes and error methods from $http service aren't the same that JQuery equivalent.

Bernhard Rode

unread,
Apr 29, 2013, 8:20:57 AM4/29/13
to ang...@googlegroups.com
Ok fine. Thanks a lot!

Michał Gołębiowski

unread,
Apr 29, 2013, 8:59:15 AM4/29/13
to ang...@googlegroups.com
Isn't Angular using full jQuery instead of jqLite if included? This would make Angular break if it detects the true jQuery and starts using it.

Bernhard Rode

unread,
Apr 29, 2013, 9:06:48 AM4/29/13
to ang...@googlegroups.com
The question is whether $http is using the jQuery methods or has its own implementation....

If jQuery aka jQlite is involved you're right, then this might be a problem in the future....

Michał Gołębiowski

unread,
Apr 29, 2013, 9:09:54 AM4/29/13
to ang...@googlegroups.com
It seems it uses neither of them. :) It uses $q based on https://github.com/kriskowal/q if I see correctly.


--
You received this message because you are subscribed to a topic in the Google Groups "AngularJS" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/angular/ixmLu9NPm8k/unsubscribe?hl=en-US.
To unsubscribe from this group and all its topics, send an email to angular+u...@googlegroups.com.
To post to this group, send email to ang...@googlegroups.com.
Visit this group at http://groups.google.com/group/angular?hl=en-US.
For more options, visit https://groups.google.com/groups/opt_out.
 
 



--
Michał Z. Gołębiowski

César González

unread,
Apr 29, 2013, 9:13:26 AM4/29/13
to ang...@googlegroups.com

Yes, angular use JQuery if this load first but angular use this only for DOM control I think so.

--

Sander Elias

unread,
Apr 29, 2013, 9:30:32 AM4/29/13
to ang...@googlegroups.com
Hi Bernard,

Well, if you look at the source of angular, you will see that Angular uses it own interpretation. No jquery/jqlite or $q for making ajax calls. 

Regards
Sander Elias

Josh David Miller

unread,
Apr 29, 2013, 7:27:05 PM4/29/13
to angular
Hello!

Just to clarify succinctly: AngularJS uses its own XHR scheme called $http, unaffected by jQuery; $http uses $q (based on Kris Kowal's Q) to store future responses or errors returned from those XHR calls as "promises".

Josh


--
You received this message because you are subscribed to the Google Groups "AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to angular+u...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages