Wiley Concise Guide to Dojo 978-0-470-45202-8 Manuale Utente

Codici prodotto
978-0-470-45202-8
Pagina di 20
Enhancing Development
with Dojo Core
This chapter shows the Dojo core of basic JavaScript language enhancements that provides the
foundation for all of the other tools and systems offered by the toolkit. But first, you learn how to
get a copy of Dojo, either from current releases or leading-edge development versions. Then, you are
taken on a tour through the basic packaging, markup declaration, and object-oriented programming
features.
Getting Dojo
It’s time to dig in and start playing with Dojo for yourself. There are several ways to do this, and
each way offers its own advantages.
Using Dojo via the AOL CDN
The easiest way to start using Dojo is by way of the AOL Content Delivery Network.
In short, the AOL CDN is a widely distributed and highly available network of web servers hosting
static assets — and among these assets are the code and collateral for the Dojo toolkit. What this
means is that you can get started using Dojo with an include like the following:
<script type="text/javascript"
src="http://o.aolcdn.com/dojo/1.1.1/dojo/dojo.xd.js"></script>
This single JavaScript include will pull in an optimized build of the Dojo core, which is enough to
get you rolling thanks to the Dojo packaging system and dynamic module loading.
COPYRIGHTED MATERIAL