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
| var ncore = require( 'ncore' ); | |
| ncore.constructor( { | |
| "other": { | |
| "test": "test" | |
| } | |
| }); | |
| console.log( ncore ); |
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 LeaderBoard(doc) { | |
| var elem = Fragment(html) | |
| , leaderBoardElem = elem.querySelector(".leaderboard") | |
| , playerSet = doc.createSet("type", "player") | |
| , oldSelected = selected.get("player") | |
| , sel = selectron() | |
| playerSet.forEach(addPlayer) | |
| playerSet.on("add", addPlayer) |
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
| * A Short but smart tutorial on basic pathfinding - http://ai-depot.com/Tutorial/PathFinding.html | |
| * http://www.html5rocks.com/en/tutorials/webaudio/games/ | |
| CSS Pro Tip |
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
| pipe(stream('water'), [ | |
| stream('bathroom'), [ | |
| stream('sink'), | |
| stream('toilet') | |
| ], | |
| stream('kitchen'), [ | |
| stream('sink'), | |
| stream('dishwasher') | |
| ], | |
| ]) |
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
| var assert = require("TAP-winning/assert")() | |
| assert.equal() ... | |
| setTimeout(function () { | |
| assert.end() | |
| }, 1000) |
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
| -var pad = function(decimal){ return decimal.toFixed(2); }; | |
| h2 Hi NoNuby | |
| div!= pad(locals.val1); | |
| div!= pad(locals.val2); |
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
| var WriteStream = require("write-stream") | |
| var toArray = require("write-stream/array") | |
| /************************************** A *************************************/ | |
| db.readStream().pipe(WriteStream(function write(data) { | |
| assert.equal(data, { | |
| value: 'value', | |
| key: 'key' | |
| }) |
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
| var parseScope = require('lexical-scope'); | |
| var browserResolve = require('browser-resolve'); | |
| var commondir = require('commondir'); | |
| var through = require('through'); | |
| var mdeps = require('module-deps'); | |
| var path = require('path'); | |
| var processModulePath = require.resolve('process/browser.js'); | |
| module.exports = function (files, opts) { |
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
| var lines = require('line-stream') | |
| , through = require('through') | |
| , emit = require('emit-function') | |
| , duplex = require('duplex') | |
| module.exports = json | |
| function json(transport) { | |
| var input = through(write) | |
| , output = through(recv) |
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
| // The well-known callback pattern | |
| fs.mkdir("some-path", function(err) { | |
| fs.open("some-path/file", "w", function(err, fd) { | |
| var buffer = new Buffer("hello world") | |
| fs.write(fd, buffer, 0, buffer.length, null, function(err, bytes) { | |
| console.log("Wrote " + bytes + " bytes") | |
| }) | |
| }) | |
| }) |