Yahoo! Developer Network Home - Help

YDN Site Search

# YUI Library Examples: Event Utility

# Event Utility: Examples

- 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.

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

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

### Event Utility:

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

Copyright © 2008 Yahoo! Inc. All rights reserved.

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