Skip to content

Instantly share code, notes, and snippets.

View terbo's full-sized avatar
💭
everybody must get annointed

CB terbo

💭
everybody must get annointed
View GitHub Profile
@mbostock
mbostock / .block
Last active June 20, 2024 01:47
Collapsible Force Layout
license: gpl-3.0
@mbostock
mbostock / .block
Last active May 24, 2024 10:13 — forked from mbostock/.block
Clustered Force Layout II
license: gpl-3.0
@mbostock
mbostock / .block
Last active April 2, 2017 15:08 — forked from mbostock/.block
Multi-Foci Force Layout
license: gpl-3.0
@mbostock
mbostock / .block
Last active December 20, 2022 03:31 — forked from mbostock/.block
Orthographic Shading
license: gpl-3.0
redirect: https://observablehq.com/@d3/orthographic-shading
@diethardsteiner
diethardsteiner / index.html
Created August 7, 2012 17:52
Simple D3JS Dashboard
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8">
<title>Testing Pie Chart</title>
<!--<script type="text/javascript" src="d3/d3.v2.js"></script>-->
<script src="http://d3js.org/d3.v2.js"></script>
<!-- Note: I made good use of the sample code provided by the D3JS community and extended it to fit my needs to create this simple dashboard -->
<style type="text/css">
@mbostock
mbostock / .block
Last active July 3, 2024 09:03
Force-Directed Graph
license: gpl-3.0
height: 600
redirect: https://observablehq.com/@d3/d3-force-directed-graph
@mbostock
mbostock / .block
Last active November 26, 2018 16:41 — forked from mbostock/.block
Rainbow Worm
license: gpl-3.0
redirect: https://beta.observablehq.com/@mbostock/rainbow-worm
@faisalman
faisalman / baseConverter.js
Last active January 11, 2023 14:43
Convert From/To Binary/Decimal/Hexadecimal in JavaScript
/**
* Convert From/To Binary/Decimal/Hexadecimal in JavaScript
* https://gist.github.com/faisalman
*
* Copyright 2012-2015, Faisalman <fyzlman@gmail.com>
* Licensed under The MIT License
* http://www.opensource.org/licenses/mit-license
*/
(function(){
@bmcbride
bmcbride / LeafletToWKT.js
Last active June 7, 2022 02:17
Leaflet layer to WKT
function toWKT(layer) {
var lng, lat, coords = [];
if (layer instanceof L.Polygon || layer instanceof L.Polyline) {
var latlngs = layer.getLatLngs();
for (var i = 0; i < latlngs.length; i++) {
latlngs[i]
coords.push(latlngs[i].lng + " " + latlngs[i].lat);
if (i === 0) {
lng = latlngs[i].lng;
lat = latlngs[i].lat;
@mbostock
mbostock / .block
Last active September 10, 2019 06:29
Craig Retroazimuthal
license: gpl-3.0