Skip to content

Instantly share code, notes, and snippets.

@keeyip
keeyip / index.html
Created October 30, 2013 13:09
UI for Ast Matcher
<style>
body {
background:hsl(200,20%,50%);
font-family:inconsolata-dz;
font-size:12px;
}
em {
font-style:itlaic;
font-weight: bold;
@keeyip
keeyip / index.html
Last active December 21, 2015 15:49
Sibilant Editor
<!doctype html>
<body>
<style>
.CodeMirror {
font-size: 16px;
}
</style>
<link rel='stylesheet' href='https://rawgithub.com/marijnh/CodeMirror/3.16.0/lib/codemirror.css'/>
<script src="https://rawgithub.com/marijnh/CodeMirror/3.16.0/lib/codemirror.js"></script>
<script src='https://rawgithub.com/marijnh/CodeMirror/3.16.0/mode/javascript/javascript.js'></script>
@keeyip
keeyip / Ast.js
Last active December 21, 2015 14:38
Visualizing code
Ast = {
isLoop: function(node) {
return /(?:For|While)Statement/.test(node.type)
}
}
@keeyip
keeyip / grid.css
Last active December 21, 2015 13:49
Grid Layout
.container {
position:relative;
background:black;
outline: solid 4px red;
display:inline-block;
vertical-align:top;
margin: 20px;
}
.cell {
text-align:center;
@keeyip
keeyip / index.html
Created December 19, 2014 02:16
gist
<a href="javascript:(function(){ var js = document.createElement('script'); js.src = 'https://syapse.atlassian.net/wiki/download/attachments/12321028/example.js?api=v2'; document.body.appendChild(js); })()
">Bookmarklet</a>
@keeyip
keeyip / index.html
Last active August 29, 2015 14:07
ie8d3-chart
<!DOCTYPE html>
<head>
<!-- no input, fixstuff 2323 -->
<meta charset="utf-8">
<script src="shim.js"></script>
<!--[if lte IE 8]><script src="r2d3.js" charset="utf-8"></script><![endif]-->
<!--[if gte IE 9]><!-->
<script src="http://d3js.org/d3.v3.min.js"></script>
<!--<![endif]-->
@keeyip
keeyip / index.html
Last active August 29, 2015 14:07
ie8d3
<!DOCTYPE html>
<head>
<meta charset="utf-8">
<!--[if lte IE 8]><script src="r2d3.js" charset="utf-8"></script><![endif]-->
<!--[if gte IE 9]><!-->
<script src="http://d3js.org/d3.v3.min.js"></script>
<!--<![endif]-->
@keeyip
keeyip / tpl.js
Created April 20, 2014 23:21
Small, fast, compiled templating engine
var tpl = (function() {
var slice = Array.prototype.slice;
function first(xs) {
return xs[0]
}
function rest(xs) {
return slice.call(xs, 1);
}
function flatten(xs) {
var flat = []
@keeyip
keeyip / index.html
Created March 22, 2014 15:01
Git visualization
<!doctype html>
<html>
<head>
<meta charset='utf-8'/>
<style>
body {
background:hsl(0,0%,50%);
}
</style>
</head>