YUI Library Home

Site Search (YDN & YUIBlog):

# YUI Library Examples: Event Utility

# Event Utility: Examples

The YUI Event Utility is part of YUI's core, and it provides DOM event management, a custom event system, and page-load timing events that are at the heart of almost any YUI implementation.

- Simple Event Handling and Processing: Demonstrates simple event attachment and use of Event Utility to provide browser-neutral methods for acting on event objects.
- Using Custom Events: Custom Events are an excellent way to publish and subscribe to interesting moments in your own scripts.
- Using onAvailable, onContentReady, and onDOMReady: Event Utility gives you control over when you execute your scripts. In addition to the window's `load` event, Event Utility lets you know when an element is available, when its children are available, and when the page's full DOM is available.
- Using Event Utility and Event Delegation to Improve Performance: Assigning events to parent elements allows you to listen for those same events on descendant elements, reducing the number of event listeners you need in your application.
- Skinning via Progressive Enhancement using the Event Utility and the YUILoader: Using Progressive Enhancement to skin checkboxes with the help of the YUILoader and the Event Utility's "focus" and "blur" events and the "delegate" method.

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

- Implementing Container Keyboard Shortcuts with KeyListener (included with examples for the Container Family)
- Using the Container ARIA Plugin (included with examples for the Container Family)

### Event 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