YUI Library Home

Site Search (YDN & YUIBlog):

# YUI Library Examples: YUI Loader Utility

# YUI Loader Utility: Examples

The YUI Loader provides a client-side mechanism for loading YUI components and their dependencies. It can be used to add additional components to a page on which some YUI components already exist or to structure the loading of scripts and CSS files for an entire page.

- Using YUI Loader to Load the Calendar Control: This example demonstrates a simple implementation in which we bring in the YUI Calendar Control — and its JavaScript and CSS dependencies — using the YUI Loader Utility.
- Using YUI Loader to Place Additional Components on a Page: In some cases, you may wish to use YUI Loader to bring additional components into a page that already contains some YUI content. In this example, we'll look at how to use YUI Loader to augment a page's existing YUI content by bringing in additional dependencies for a new component.
- Using addModule to Add Custom (Non-YUI) Content with YUILoader: YUILoader can be used to add YUI components to the page, but it can also be used to add other components that you create yourself (or that you pull from a third-party source). This example shows one simple way to pull in external content with YUILoader.
- Use YUILoader to list requirements for a set of components.: Select one or more YUI components and see an optimized list of file includes.

## Other YUI Examples That Make Use of the YUI Loader Utility

- Skinning via Progressive Enhancement using the Event Utility and the YUILoader (included with examples for the Event Utility)
- Complex Application (included with examples for the Layout Manager)

### YUI Loader Utility:

- User's Guide (external)
- API Documentation
- Cheat Sheet PDF(external)

Copyright © 2010 Yahoo! Inc. All rights reserved.

Privacy Policy - Terms of Service - Copyright Policy - Job Openings