Skip to content

Instantly share code, notes, and snippets.

View richardwestenra's full-sized avatar
🍅
Certified Fresh

Richard Westenra richardwestenra

🍅
Certified Fresh
View GitHub Profile
@richardwestenra
richardwestenra / index.html
Last active April 20, 2018 18:42
Alternate favicon demo
<html>
<head>
<title>Alternate Favicon switcher</title>
<link id="favicon" rel="shortcut icon" href="https://i.imgur.com/FfxiVKR.png" />
<meta name="theme-color" content="#000000">
</head>
<body>
<h1>Alternate Favicon switcher</h1>
<p>This page demonstrates how a favicon can be swapped out on pages which support and utilize the theme-color meta tag.</p>
<p>Open on <a href="https://bl.ocks.org/richardwestenra/raw/a967af7ec943b8f012ba3e68c1492622/">bl.ocks.org</a> on both a mobile and desktop browser to see it in action.</p>
@richardwestenra
richardwestenra / index.html
Created June 25, 2015 10:22
d3.geo.path + canvas + pattern image fill
<!DOCTYPE html>
<meta charset="utf-8">
<body>
<script src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.5/d3.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/topojson/1.6.19/topojson.min.js"></script>
<script>
var width = 960,
height = 500;
$(function(){
// Define some global variables:
var timeStamp = {
start: 0,
stop: 0,
duration: 0
};
// Calculate how close a number is to 5.
@richardwestenra
richardwestenra / index.html
Last active August 10, 2016 11:56
Turn.js "fixed" class IE bug
<!DOCTYPE html>
<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7" lang="en" itemscope itemtype="http://schema.org/Article"> <![endif]-->
<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8" lang="en" itemscope itemtype="http://schema.org/Article"> <![endif]-->
<!--[if IE 8]> <html class="no-js lt-ie9" lang="en" itemscope itemtype="http://schema.org/Article"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" itemscope itemtype="http://schema.org/Article"> <!--<![endif]-->
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width">