Mike Robinson
Mike Robinson

Reputation: 25159

What is good javascript ajax library for a custom library?

A little explanation: I'm building a library to handle some back and forth with our CMS and have decided to open source it. Right now I have a dependency on jQuery 1.5 for it's AJAX method, specifically the recently added statusCode object. This is the only depency, and I'm not expecting others.

Are there any lightweight AJAX only libraries out there capable of this functionality? I'd rather not include all of jQuery if necessary.

Upvotes: 2

Views: 775

Answers (4)

Raynos
Raynos

Reputation: 169451

Look at ender. Which allows you to include only what you want. I believe the ajax library included is very small.

You should avoid Single points of failure like having other services host code for you.

Upvotes: 3

Hussein
Hussein

Reputation: 42818

Why not call jQuery directly from google. Since most users use google, many will already have jQuery cached and will not have the need to reload jQuery when accessing your site.

<script src=" http://ajax.googleapis.com/ajax/libs/jquery/1.5.2/jquery.min.js" type="text/javascript"></script>

Check out this blog 3 reasons why you should let google host your jQuery. http://encosia.com/2008/12/10/3-reasons-why-you-should-let-google-host-jquery-for-you/

Upvotes: 2

Keith
Keith

Reputation: 43044

I like Mochikit, but it does more that just AJAX, but has a better async handling method using the Deferred object. It is smaller than Jquery.

Upvotes: 0

Related Questions