Combo Handler Service Available for Yahoo-hosted JS
We've been talking for a long time at Yahoo about the importance of minimizing HTTP requests to improve performance. One important technique for YUI users has long been to use the pre-built "rollup" files (like
yahoo-dom-event.js, which combines the YUI Core in a single minified HTTP request) and to create custom rollups that aggregate all of your YUI JS content in a single file. You'll notice that we do a lot of this on our core Yahoo properties. For example, if you go to check on the Tour de France on Yahoo! Sports, you'll find that numerous YUI components are aggregated with custom Sports-specific JS resources in a single HTTP request (here's the aggregate file).
Thanks to the hard work of the Yahoo Exceptional Performance team and the groups that support our CDN, we're now able to offer ad-hoc file aggregation — "combo handling" — to file served from
yui.yahooapis.com. So, a request for the full YUI Rich Text Editor, which previously looked like this...
...can now be written this way:
In one step, this eliminates five separate HTTP requests.
- If you're using the YUI Configurator, this option ("Combine All JS Files") is enabled by default as long as you're using the default base path.
- Combo-handling of YUI CSS files is not supported at this time.
- In an upcoming release, we'll provide built-in combo-handling support in YUI Loader and restructure filepaths in YUI's CSS resources to make them combinable as well.
- YUI Configurator will always output the current version of the library, but all YUI JS files from 2.2.0 onward are present on
yui.yahooapis.comand can be combined using the same combo-handling syntax.
We hope combo handling provides a easy performance win for those of you letting Yahoo serve your YUI files. Discussion of combo handling and all YUI issues takes place in our community forum — please join us there and let us know how this works for you.