Skip to content

Instantly share code, notes, and snippets.

@homam
homam / .block
Created August 29, 2018 12:41 — forked from micahstubbs/.block
world map 07 Jenks natural breaks
height: 510
border: no
license CC0-1.0
@homam
homam / index.html
Last active July 6, 2016 12:39 — forked from d3noob/.block
Sankey from csv with d3.js
<!DOCTYPE html>
<meta charset="utf-8">
<title>SANKEY Experiment</title>
<style>
.node rect {
cursor: move;
fill-opacity: .9;
shape-rendering: crispEdges;
}
@homam
homam / nginx
Last active August 29, 2015 14:14 — forked from psd/nginx
map $query_string $new_url {
~a=1 http://www.gov.uk/1;
~a=2 http://www.gov.uk/2;
~a=3&b=1|b=1&a=3 http://www.gov.uk/31;
~\ba=4\b.*\bb=2\b|\bb=2\b.*\ba=4\b http://www.gov.uk/42;
}
server {
server_name lrc.businesslink.gov.uk;
@homam
homam / README.md
Last active December 1, 2020 22:45 — forked from mbostock/.block
D3 General Upadte Pattern in LiveScript

By adding transitions, we can more easily follow the elements as they are entered, updated and exited. Separate transitions are defined for each of the three states.

Note that no transition is applied to the merged enter + update selection; this is because it would supersede the transition already scheduled on entering and updating elements. It's possible to schedule concurrent elements by using transition.transition or by setting transition.id, but it's simpler here to only transition the x-position on update; for entering elements, the x-position is assigned statically.

Want to read more? Try these tutorials:


This fork shows how using LiveScript improves readability of D3 enter-update-exit pattern.

@homam
homam / index.html
Last active December 31, 2015 07:09 — forked from jraycv/CSS3 Center Radial
<!DOCTYPE html>
<html>
<head>
<title>Conversion</title>
<link type="text/css" rel="stylesheet" href="radial.css" />
</head>
<body class="radial">
hello
</body>
</html>