This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function ajaxize(selector) { | |
$(selector).each(function(idx, el) { | |
el = $(el); | |
var opts = (el.attr('rel') || '').split(' '); | |
var hasOption = function(opt) { return opts.indexOf(opt) > -1 } | |
var pos = hasOption('before') ? 'Before' : 'After'; | |
var toggle = hasOption('toggle'); | |
var increase = hasOption('increase'); | |
var inherit = hasOption('inherit'); | |
var target_name = el.attr('target'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with (require('./nano')) { | |
get('/hello', 'Hello, world'); | |
get('/index.html', readfile('index.html')); | |
static_file('/about.html'); | |
get('/bye', function() { | |
return 'Bye~ ' + request.args['name']; | |
}); |
NewerOlder