Setup and Configuration
To set up and configure the application, download the accompanying source files
, an Eclipse plug-in that supports numerous AJAX libraries including YUI. However, I have found that Aptana's autocomplete doesn’t always work for YUI.
Take the following steps to complete the setup and configuration for the demo application:
- Create a folder js-lib/yui where the index.html file will be located. Download the YUI library and copy the build folder to js-lib/yui as well.
- Open the index.html file in FireFox. I did not test the demo application against IE, so you might experience some errors if you choose to use that browser.
You are better off retaining the folder structure of the YUI library. Otherwise, some features may not work as expected, especially those relating to look and feel. This is because the style definitions contain relative paths.
Debugging with Firefox and Firebug
is a very useful Firefox add-on for debugging rich client web applications. Firefox and Firebug together offer the following features:
- Selecting a div in the HTML tab highlights the screen area in the loaded page.
- Modification to CSS properties gets reflected instantly in the loaded page, greatly reducing the time you would spend getting the desired look and feel for the application.
- You can further analyze a selected element in the HTML tab by opening DOM or Layout tabs. The Layout tab is especially useful for calculating pixels occupied by a UI element. This is important because pixels are allotted to margins and borders, in addition to the actual width and height of the element.