If you ask this question on comp.lang.javascript, you will get many different answers, many of which neglect the widely used libraries (one quote, sometimes taken a little out of context, Richard Kornford's post in cljs in 2007 : "Prototype.js was written people who donβt know javascript for people who donβt know javascript. People who donβt know javascript are not the best source for designing systems using javascript. ")
An argument for libraries - they abstract most of the differences between browsers and allow the use of cross-browser scripts. The argument against libraries is that they are bloated code with their own quirks, so you have to learn to use them just as well as use cross-browser methods in raw javascript. If you write a lot of Javascript that you intend to reuse in several places, and you try to load websites quickly and quickly and use the minimum bandwidth (for example, if you use pay-per-use web hosting, for example via Amazon S3 or nearlyfreespeech. net ), then itβs probably worth stripping everything you intend to use from a good library, configure it and use it.
I thought about Prototype for a while, but then decided that I just needed some simple building blocks. I usually use the Doug Crockford simple JSON library , and then some of the Fork Javascript minimalist libraries as needed (primarily FORK.Ajax ), and do the rest myself from scratch or reuse routines from an earlier project that I honed to which something that works well for me.
Jason s
source share