This file contains 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
traceur --out out.js parser.js | |
# Traceur does not strip dead code. Use Uglify2. | |
uglifyjs src/runtime/runtime.js out.js -cm -o out.min.js |
This file contains 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
// http://paulirish.com/2011/requestanimationframe-for-smart-animating/ | |
// http://my.opera.com/emoller/blog/2011/12/20/requestanimationframe-for-smart-er-animating | |
// requestAnimationFrame polyfill by Erik Möller. fixes from Paul Irish and Tino Zijdel | |
// MIT license | |
(function() { | |
var lastTime = 0; | |
var vendors = ['ms', 'moz', 'webkit', 'o']; |
This file contains 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
Introduction | |
============ | |
The Hydna Protocol is a TCP/IP-based, application layer procotol designed | |
to facilitate high performance one-to-many real time communication. It is | |
an asynchronous protocol, albeit a few internal operations rely on | |
chat-style communication. | |
It is a very terse, multicasting, binary protocol that is well-suited for | |
rapidly sending large amounts of small packets. |
This file contains 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 FoldArrayRev (chunkSize) { | |
this._chunkSize = chunkSize || 1000; | |
this._data = [[]]; | |
this._tail = 0; | |
} | |
FoldArrayRev.prototype = { | |
push: function (item) { | |
if (this._data[this._tail].length >= this._chunkSize) { | |
this._data[this._tail] = this._data[this._tail].reverse(); | |
this._data.push([]); |