views:

256

answers:

2

I have thought hard about what library would be best, but any library "X" would be missing a certain feature from library "Y".

What are peoples' thoughts on using mutliple JavaScript libraries simultaneously?

+1  A: 

Use jQuery and its plugins. You'll never not have the feature you need :). I don't see anything wrong with using multiple libraries, but it is nice to stay within a single framework...it makes dealing with code and managing a codebase a bit easier.

Stefan Kendall
+3  A: 

Quite simply, don't do it. You'll have headaches with:

  1. Inconsistent code in your application ($('element') vs $('#element'))
  2. Possible conflicting libraries (Date.prototype.toJSON() is often defined in libs)
  3. Additional overhead for your users to download, thus worse user experience
  4. More documentation to keep track of, thus larger learning curve for new devs
  5. More code to keep updated and secure
  6. More time spent figuring out which library you want to use for what.

If you have some specific need that a different library addresses, pull the pieces of that library as needed. It'll save you way more time than it takes to extract what you need.

jvenema