Skip to content

Instantly share code, notes, and snippets.

@jstcki
jstcki / README.md
Created November 20, 2014 17:44
React-D3 Components

React-D3 components.

@jstcki
jstcki / index.js
Created November 10, 2014 10:02
requirebin sketch
var Intl = require('intl');
console.log(new Intl.NumberFormat('de-ch', {style:'currency', currency:'chf'}).format(123456.789));
@jstcki
jstcki / .gitignore
Last active August 29, 2015 13:58
WFS to TopoJSON
.DS_Store
build
node_modules
@jstcki
jstcki / README.md
Last active March 23, 2016 15:04
React Map Component

A variation of this map. The SwissMap component gets passed a url property with which it attempts to load the map data. When the loading callback fires it updates its state and gets re-rendered. Reload the page if the loading fails (the URL has a 30 % chance to be invalid).

@jstcki
jstcki / README.md
Last active April 12, 2017 13:24
Transitions with React and D3 II

Using D3 in a React TransitionGroup to transition elements. D3 is used purely for transitions, not for data joins. The distinction between entering and exiting elements is handled by the TransitionGroup component. See the React documentation for further information.

Alternative implementations only with D3 and using React without addons.

Note: This implementation is around 30% slower in processing 1000 circles than the other two.

@jstcki
jstcki / README.md
Last active April 12, 2017 13:24
Transitions with React and D3 I
@jstcki
jstcki / README.md
Last active August 29, 2015 13:56
Transitions with D3

Avoid restarting running transitions by either starting one just on the .enter() selection or by using selection.filter() to only select elements which are not in transit yet.

Alternative implementations combining D3 with React and React TransitionGroup.

@jstcki
jstcki / README.md
Last active May 25, 2021 11:36
Swiss Cantons and Municipalities with React
@jstcki
jstcki / README.md
Last active September 11, 2020 17:16
Swiss Municipality Coordinates

Extract and list Swiss municipality coordinates from TopoJSON.

@jstcki
jstcki / README.md
Last active December 1, 2018 13:34
Swiss Topography