Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Ajax - Library or Plain Javascript

I've been doing a lot of reading about AJAX, and wanted to know which is the better way to approach things: by using a library such as jQuery using their built-in methods or creating JavaScript without a library for AJAX?

like image 987
jrutter Avatar asked Dec 27 '08 13:12

jrutter


1 Answers

Ajax has a lot of quirks when working with the XMLHttpRequest Object. When you start to work with it, you will not see it, but when it is out in a production environment, it will bite you in the butt. Browsers, browser version, user settings, the type of server, type of request, and much more can affect what needs to be coded. Libraries tend to solve most of the problems, but they all are not perfect.

I always tell people it is great to work with a tutorial to see how the XMLHttpRequest works. After you have learned how to do it naked, work with a library that fits your needs.

Eric Pascarello

like image 73
epascarello Avatar answered Sep 28 '22 06:09

epascarello