JavaScript Libraries
JavaScript Libraries - jQuery, Prototype, MooTools.
JavaScript Frameworks (Libraries)
Advanced JavaScript programming (especially the complex handling of browser differences) is usually difficult and time-consuming.
To cope with these adjustments, many JavaScript (helper) libraries have emerged.
These JavaScript libraries are often called JavaScript frameworks。
In this tutorial, we will look at some popular JavaScript frameworks:
- jQuery
- Prototype
- MooTools
All these frameworks provide functions for common JavaScript tasks, including animation, DOM manipulation, and Ajax handling.
In this tutorial, you will learn how to start using them to make JavaScript programming easier, safer, and more fun.
jQuery
jQuery is currently the most popular JavaScript framework.
It uses CSS selectors to access and manipulate HTML elements (DOM objects) on a web page.
jQuery also provides a companion UI (user interface) and plugins.
Many large companies use jQuery on their websites:
- Microsoft
- IBM
- Netflix
To learn more about jQuery, visit our jQuery tutorial。
Prototype
Prototype is a library that provides a simple API for performing common web tasks.
API stands for Application Programming Interface. It is a library containing properties and methods for manipulating the HTML DOM.
Prototype enhances JavaScript by providing classes and inheritance.
MooTools
MooTools is also a framework that provides an API to make common JavaScript programming simpler.
MooTools also contains some lightweight effects and animation functions.
Other Frameworks
Here are some other frameworks not mentioned above:
YUI - Yahoo! User Interface Framework, a large library covering a wide range of functions, from simple JavaScript features to complete internet widgets.
Ext JS - Customizable widgets for building rich Internet applications.
Dojo - A toolkit for DOM manipulation, events, widgets, and more.
script.aculo.us - An open-source JavaScript framework for visual effects and interface behavior.
UIZE - Widgets, AJAX, DOM, templates, and more.
CDN - Content Delivery Network
You always want your web pages to be as fast as possible. You want the page size to be as small as possible, and you want the browser to cache as much as possible.
If many different websites use the same JavaScript framework, it makes sense to store the framework library in a common location for every web page to share.
CDN (Content Delivery Network) solves this problem. A CDN is a network of servers containing shareable code libraries.
Free CDN resources in China include:
- Staticfile CDN:https://staticfile.net/
Free CDN resources overseas include:
- cdnjs:https://cdnjs.com/
To use a JavaScript framework library in your web page, simply