Skip to content

Instantly share code, notes, and snippets.

View rustybailey's full-sized avatar

Rusty Bailey rustybailey

View GitHub Profile

Day 1

May 27, 2015

Microsoft Developer Advocate for Internet Explorer. Contributing Editor to Smashing Mag.

Woah, You Can Test IE / Microsoft Edge on a Mac & Linux?

How can I know developers pain points without working in the same environment as developers. That's why I use a Mac.

@LordNed
LordNed / DiffuseSpriteFlash.shader
Last active November 23, 2020 14:08
2D Sprite Blinking
Shader "Sprites/Diffuse Flash"
{
Properties
{
[PerRendererData] _MainTex ("Sprite Texture", 2D) = "white" {}
_SelfIllum ("Self Illumination",Range(0.0,1.0)) = 0.0
_FlashAmount ("Flash Amount",Range(0.0,1.0)) = 0.0
_Color ("Tint", Color) = (1,1,1,1)
[MaterialToggle] PixelSnap ("Pixel snap", Float) = 0
}
{
"bitwise": true,
"camelcase": true,
"eqeqeq": true,
"forin": true,
"immed": true,
"latedef": "nofunc",
"newcap": true,
"noarg": true,
"noempty": true,
@8bitDesigner
8bitDesigner / burnThem.js
Last active December 19, 2015 05:19
Find and log every DOMNode on the page which isn't using Proxima Nova as its font-family
// Find and log every DOMNode on the page which isn't using Proxima Nova
// as its font-family
function isHeretic(node) { return (window.getComputedStyle(node).fontFamily.indexOf('proxima-nova') < 0) }
function isVisible(node) { return (window.getComputedStyle(node).display !== 'none') }
function log(node) { console.log(node, window.getComputedStyle(node).fontFamily) }
function toArray(domlist) { return Array.prototype.slice.call(domlist) }
toArray(document.querySelectorAll('#fs-main-content *')).filter(isHeretic).filter(isVisible).forEach(log)
@streunerlein
streunerlein / gist:3332181
Created August 12, 2012 14:58
NPM Mirrors & Proxies

Definition

Mirrors: standalone servers with complete copy of npm registry

Proxies: proxy to the database (couchdb) of npm registry, if only the npm registry server fails but the db works

## HowTo See this gist: https://gist.github.com/3331671

Mirrors

(+) means server is self updating (pulls newest stuff from offical registry when back online again)

@biovisualize
biovisualize / index.html
Created June 9, 2011 14:42
Simple D3 tooltip
<!DOCTYPE html>
<html >
<head>
<script type="text/javascript" src="http://mbostock.github.com/d3/d3.js"></script>
</head>
<body>
<div class="example_div"></div>
<script type="text/javascript">
var tooltip = d3.select("body")
.append("div")