The default evaluator will automatically load Node.js core modules into the REPL environment when used... https://nodejs.org/api/repl.html
$ node
> querystring.parse("")
{}
Easy peezy lemon sqeezy!
The default evaluator will automatically load Node.js core modules into the REPL environment when used... https://nodejs.org/api/repl.html
$ node
> querystring.parse("")
{}
Easy peezy lemon sqeezy!
http://gsgd.co.uk/sandbox/jquery/easing/jquery.easing.1.3.js https://github.com/gdsmith/jquery.easing/blob/master/jquery.easing.js#L21
Relevant parts
// Preserve the original jQuery "swing" easing as "jswing"
$.easing['jswing'] = $.easing['swing'];
$.extend( $.easing,
#!/usr/bin/env node | |
// 1. add shebang above | |
// 2. make file executable | |
// $ chmod +x pipeToMe.js | |
// 3. pipe from file | |
// $ cat file | ./pipeToMe.js | |
// 4. pipe from echo | |
// $ echo -n one two | ./pipeToMe.js | |
// 5. just pass some args |
function secretary(people, weekNumber){ | |
var index = weekNumber % people.length; | |
return people[index]; | |
} |
// http://stackoverflow.com/a/2117523/1983554 | |
function createId() { | |
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx' | |
.replace(/[xy]/g, function(c) { | |
var r = Math.random()*16|0, v = c == 'x' ? r : (r&0x3|0x8); | |
return v.toString(16); | |
}); | |
} |
https://nodejs.org/api/fs.html#fs_class_fs_stats
var ts = fs.statSync(file).mtime.getTime()
interactive http://bl.ocks.org/abernier/3070589
node docs https://nodejs.org/api/url.html#url_url https://nodejs.org/api/http.html#http_http_request_options_callback
# protocol
http://www.foo.io/path/to/stuff?foo=bar&bar=5