
http://yuiblog.com/blog/category/in-the-wild/
<script
src="http://yui.yahooapis.com/3.6.0
/build/simpleyui/simpleyui-min.js">
</script>
<script>
Y.one("#foo").addClass("highlight");
</script>
// get an element reference, add a click handler
Y.one('#demo').on('click',
function(e) {/*handle click*/});
// add content to an element
Y.one('#demo').append('Added to #demo.');
// listen for any click on any <li>
// that descends from #demo:
Y.one('#demo').delegate('click',
function(e) {/*handle click*/}, 'li');
// move #demo to the location of any click
Y.one('document').on('click', function(e) {
Y.one('#demo').setXY([e.pageX, e.pageY]);
}
);
Y.one('#demo').transition({
easing: 'ease-out',
duration: 2, // seconds
opacity: 0
}, function() {
this.remove();
});
Y.io('/get-data', {
on: {
complete: function (id, response) {
var data = response.responseText;
// handle the response
}
}
});
Y.use('dd-drag', function(Y) {
var dd = new Y.DD.Drag({
node: '#foo'
});
});
Y.use('yql', function (Y) {
var res = Y.one('#res'), zip = '90210';
Y.YQL('select * from weather.forecast'
+ ' where location=' + zip, function (r) {
var item = r.query.results.channel.item;
var el = Y.Node.create('div');
el.setContent('<h2>Weather for '
+ zip + '</h2>'
+ item.description);
res.appendChild(el);
});
});
Great resource for jQuery users.

http://yuilibrary.com/projects/nodejs-yui3
$ npm install yui3
See http://npmjs.org.
app.get('/three', function(req, res){
res.render('same.html', {
locals: {
content: '#content',
before: function(Y) {
Y.one('h1').set('innerHTML', 'Welcome to Page #3');
},
after: function(Y, options, partial) {
Y.one('title').set('innerHTML', 'Page #3');
Y.all('#nav li').removeClass('selected');
Y.one('#nav li.three').addClass('selected');
}
})
});
http://jaisanth.com/slick-hacks-with-yui/