Skip to content

Instantly share code, notes, and snippets.

View plmrry's full-sized avatar
🦆
converting JSON to other JSON

Paul Murray plmrry

🦆
converting JSON to other JSON
View GitHub Profile
@plmrry
plmrry / capture.js
Created October 27, 2016 19:30
Capture XHR Requests
(function() {
var XHR = XMLHttpRequest.prototype;
var open = XHR.open;
var send = XHR.send;
XHR.open = function(method, url) {
requests.push(this);
this._method = method;
this._url = url;
return open.apply(this, arguments);
@plmrry
plmrry / .gitignore
Last active September 30, 2016 21:16
Sequential Tests with Tape and Bash
node_modules
@plmrry
plmrry / .block
Last active May 17, 2017 14:15
Collision Radius Transition
license: gpl-3.0
@plmrry
plmrry / .block
Last active July 27, 2016 02:48
Force Transition
license: gpl-3.0
@plmrry
plmrry / .block
Last active July 13, 2016 13:06
Babel Standalone Template
license: gpl-3.0
@plmrry
plmrry / README.md
Last active July 7, 2016 15:21
List Order Transitions

To transition an HTML list when it is re-ordered:

  • Create a second "hidden" list where each <li> contains an empty &nbsp; character.
  • Calculate each hidden <li>'s new position (using jQuery).
  • Transition the absolute-ly positioned list elements.

🆒

@plmrry
plmrry / .block
Last active July 18, 2017 20:41
Graph Experiments I
license: gpl-3.0
@plmrry
plmrry / README.md
Last active July 27, 2016 02:49
Streaming Hierarchy

This example demonstrates how to build a nested hierarchy from a streaming datasource.

Groups in the hierarchy are generated and sorted "on demand" as they are pulled from the data$ Observable.

Rx.Observable.groupBy() produces GroupedObservables which are scanned into arrays and then combined using flatMapLatest(Rx.Observable.combineLatest).

(Note: It's important to shareReplay the GroupedObservables)

This example also uses babel-standalone to enable in-browser ES6 features.

@plmrry
plmrry / README.md
Last active March 28, 2016 19:39
Mondrian

An experiment in translating from SVG into WebGL (via Three.js).

From a class project that involved a creative re-creation of the work of Piet Mondrian.

(Originally written in CoffeeScript, so the code is a little weird.)

@plmrry
plmrry / .block
Last active May 17, 2017 14:12
Clock
license: mit