Skip to content

Instantly share code, notes, and snippets.

@spullara
Created May 3, 2010 04:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save spullara/387736 to your computer and use it in GitHub Desktop.
Save spullara/387736 to your computer and use it in GitHub Desktop.
var sys = require("sys");
var fab = require('./lib/fab');
var mu = require('./lib/Mu/lib/mu');
mu.templateRoot = './templates';
(fab)
(fab.listen, 0xFAB)
(/^\/$/)
(function () {
var send = this;
mu.render("helloworld.html", {title:"Test", who:"world"}, {}, function (err, output) {
if (err) {
throw err;
}
output.addListener('data', function (c) {
send({body:c});
}).addListener('end', function () {
send();
});
});
})
(404);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment