View gist:61687b05fcf78a17576d
javascript:var cssLink=document.createElement('style');cssLink.innerHTML="@font-face { font-family: SansBS; src: url('data:font/ttf;base64,AAEAAAASAQAABAAgRkZUTVGwM9YAAKaYAAAAHEdERUYAJgDYAACmtAAAAB5HUE9T8lpNXgAAptQAABLAR1NVQhvFOicAALmUAAAV5k9TLzKg07VlAAABqAAAAGBjbWFwoIGYEgAABWAAAAGiY3Z0IDl+PkwAABD4AAAB/GZwZ21zhINeAAAHBAAABwVnYXNwAAQABwAApowAAAAMZ2x5Zs5ZPbgAABSkAACJQGhlYWQml1fWAAABLAAAADZoaGVhNgItRwAAAWQAAAAkaG10eMXDVZsAAAIIAAADWGxvY2EqhwaaAAAS9AAAAa5tYXhwA34GYgAAAYgAAAAgbmFtZefcI3UAAJ3kAAAGoHBvc3TfQqePAACkhAAAAgVwcmVwgtwhEwAADgwAAALsAAEAAAABAAB5kUCqXw889QAdCAAAAAAAyBdP9gAAAADRFL1c/qD+FC+aB3MAAAAIAAIAAAAAAAAAAQAAB3P+FAAAL7r+oP6iL+wAAQAAAAAAAAAAAAAAAAAAANYAAQAAANYE+AAXAFMABAACABAALwBaAAACHwDlAAMAAQADBCYBkAAFAAgFmgUzAAABHgWaBTMAAAPQAGYB8gAAAgsGBgMIBAICBOAAAu9AACBbAAAAKAAAAAAxQVNDAEAAICBEBh/+FACEB3MB7CAAAZ8AAAAABEoFtgAAACAAAggAAAAAAAAACAAAAAIUAAACJwCTAzcAhQUrADMEaAB7BpoAZgWeAG0BzwCFAmgAUgJoAD0EaABSBGgAZgIAAD8CkwBSAiUAkwL8ABQEaABiBGgAsgRoAGAEaABSBGgAFwRoAIMEaABxBGgAWgRoAGoEaABqAiUAkwIlAD8EaABmBGgAZgRoAGYDaAAlB
View gist:a264fba207527d775032
1 2 3 4 5 6 7 8 9 10
try {
 
var WAIT = "wait"
var FIRE = "fire"
var ACTIONS = [WAIT, FIRE]
 
if (!context.classesDefined) {
context.classesDefined = true;
context.WorldState = function WorldState(numberOfAsteroids, asteroidX, asteroidVx, fired) {
this.asteroidX = asteroidX
View gist:5380463
1 2 3 4 5 6 7 8 9 10
 
// Bad behaviour ahead!
// doesn't work with strict mode.
 
function local(obj) {
var global = Function("return this")();
var tmpName = "_tmp";
while (tmpName in global) {
tmpName = "_"+tmpName;
}
View watchFile monkey patch.js
1 2 3 4 5 6 7 8 9 10
var os = require('os');
 
if (os.platform() == 'win32') {
// change fs.watchFile so that it doesn't throw an error on windows.
fs.watchFile = function(filepath, callbackfunc) {
var old = fs.statSync(filepath);
fs.watch(filepath, function() {
fs.stat(filepath, function(err, newStat) {
callbackfunc(old, newStat);
View example.html
1 2 3 4 5 6 7 8 9 10
<html>
<head>
<title>CouchTest</title>
<script>
document.domain = window.location.hostname;
window.oncouchready = function(api) {
CouchDB = api;
var database = new CouchDB("somedb");
View couch-x.html
1 2 3 4 5 6 7 8 9 10
<html>
 
<head>
 
<script type="text/javascript" src="/_utils/script/couch.js"></script>
 
<script type="text/javascript">
document.domain = window.location.hostname;
if (window.parent.oncouchready) {
Something went wrong with that request. Please try again.