A collection of the simplest possible examples of how to use XUI to build mobile web apps.
An XUI object is instantiated with the x$ method accepting any element, css selector or array of selectors as an argument.
// any element
x$(window)
// a css selector
x$('ul#nav li a.selected');
// an array of selectors
x$(['li', 'div#foo']);
Rather often you want to do something with just the first element in the collection.
// returns the first element
x$('li').first();
Used internally by nearly every method in XUI to loop through the element collection.
// each iterator
x$('button').each(function(element){
});