(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
* Empty cache | |
npm cache clean | |
* Uninstall module | |
npm uninstall [module_name] | |
* Install module version | |
npm install [module_name]@[version] |
var WIDTH, HEIGHT, canvas, con, g; | |
var pxs = []; | |
var rint = 50; | |
$(document).ready(function() { | |
$('.get-year').text(new Date().getFullYear()); | |
var $clones = $(".testimonial-list li").clone().sort(function() { | |
return 0.5 - Math.random(); | |
}).slice(0, 4).removeClass("hidden"); | |
$(".testimonial-list").empty().append($clones); | |
var windowSize = function() { |
body { | |
font-family: Helvetica, arial, sans-serif; | |
font-size: 14px; | |
line-height: 1.6; | |
padding-top: 10px; | |
padding-bottom: 10px; | |
background-color: white; | |
padding: 30px; } | |
body > *:first-child { |
/* | |
GITHUB MARKDOWN EXTRACTOR RULES | |
https://guides.github.com/features/mastering-markdown/ | |
http://www.table-ascii.com/ | |
http://www.loc.gov/marc/specifications/specchartables.html | |
http://www.utf8-chartable.de/unicode-utf8-table.pl |
var fs = require('fs'); | |
Int64 = require('node-int64'); | |
var varint = require('varint'); | |
var lazy = require("lazy"); | |
// http://braindrivendevelopment.com/2013/10/31/reading-a-file-in-node-js/ | |
// http://lucene.apache.org/core/3_0_3/fileformats.pdf | |
var bufferSegmentGen = fs.readFileSync('./segments.gen'); | |
var bufferSegments = fs.readFileSync('./segments_4o4'); |
/*********************************************************/ | |
// Exercise: Readers | |
// https://tour.golang.org/methods/11 | |
package main | |
import "code.google.com/p/go-tour/reader" | |
type MyReader struct{} |
// Exercise 1 | |
//============== | |
// Refactor to remove all arguments by partially applying the function | |
var words = function(str) { | |
return _.split(' ', str); | |
}; | |
var match = R.curry(function(what, x) { | |
return x.match(what); |
// Example Data | |
var CARS = [ | |
{name: "Ferrari FF", horsepower: 660, dollar_value: 700000, in_stock: true}, | |
{name: "Spyker C12 Zagato", horsepower: 650, dollar_value: 648000, in_stock: false}, | |
{name: "Jaguar XKR-S", horsepower: 550, dollar_value: 132000, in_stock: false}, | |
{name: "Audi R8", horsepower: 525, dollar_value: 114200, in_stock: false}, | |
{name: "Aston Martin One-77", horsepower: 750, dollar_value: 1850000, in_stock: true}, | |
{name: "Pagani Huayra", horsepower: 700, dollar_value: 1300000, in_stock: false} | |
]; |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
FetchImageAsBlob('https://gist.github.com/fluidicon.png', function(err, img) { | |
if (err) { | |
console.log(err); | |
return; | |
} | |
// play with img | |
}); |