Skip to content

Instantly share code, notes, and snippets.

View AdrianRossouw's full-sized avatar

Adrian Rossouw AdrianRossouw

View GitHub Profile
@AdrianRossouw
AdrianRossouw / keybase.md
Created April 21, 2014 13:13
keybase.md

Keybase proof

I hereby claim:

  • I am Vertice on github.
  • I am adrianrossouw (https://keybase.io/adrianrossouw) on keybase.
  • I have a public key whose fingerprint is 2D21 FDAE AEB8 71AC 89F1 105D 9AC1 7A0B A656 E74C

To claim this, I am signing this object:

@AdrianRossouw
AdrianRossouw / readme.md
Last active August 29, 2015 14:01
Graft.io: full-stack js-based microservices

There are some really big changes that are starting to unfold across the web ecosystem in the next few months, and we have a rare opportunity to affect a major change to the way that we perceive and build software.

Trends and Influences

This route captures all of the influences on this system

Advancements on the server

These terms did not have their own wikipedia pages

  • Bleeding edge: Operating with cutting-edge technologies that are still untested and/or unstable, leading to cost overruns, under-performance, and/or delayed delivery
  • Lost in the weeds: Decision-making stalled by focusing too much on tiny details
  • Revolving door: An organization or team with high staff turnover that struggles to be effective, especially in maintaining continuity or business knowledge
  • Top-down management: A style of management where decisions and ideas too often start at the top and are passed down through successive levels
  • Typecasting: Locking successful employees into overly-safe, narrowly-defined, predictable roles based on their past successes rather than their potential
/* globals define */
define(function(require, exports, module) {
'use strict';
// import dependencies
var Engine = require('famous/core/Engine');
var Surface = require('famous/core/Surface');
var EventHandler = require('famous/core/EventHandler');
var View = require('famous/core/View');
var Transform = require('famous/core/Transform');
var Engine = require('famous/core/Engine');
var Surface = require('famous/core/Surface');
var FlexibleLayout = require('famous/views/FlexibleLayout');
var mainContext = Engine.createContext();
var colors = [
'rgba(256, 0, 0, .7)',
'rgba(0, 256, 0, .7)',
'rgba(0, 0, 256, .7)'
@AdrianRossouw
AdrianRossouw / main.js
Last active August 29, 2015 14:03
cards from the famous examples
/**
* Deck
* -----------
*
* Deck is a SequentialLayout that can be open and closed
* with defined animations.
*
* In this example, we can see that when we click we end up
* opening the decks so that their contents expand outwards.
*/
@AdrianRossouw
AdrianRossouw / main.js
Created July 15, 2014 04:23
famous easing
var Engine = require('famous/core/Engine');
// if you're ready, i am ready!
var Surface = require("famous/core/Surface");
var Modifier = require("famous/core/Modifier");
var Transform = require("famous/core/Transform");
@AdrianRossouw
AdrianRossouw / main.js
Last active August 29, 2015 14:03
famous snap
// import dependencies
var Engine = require("famous/core/Engine");
var Surface = require("famous/core/Surface");
var Modifier = require("famous/core/Modifier");
var Transform = require("famous/core/Transform");
var Transitionable = require("famous/transitions/Transitionable");
var SnapTransition = require("famous/transitions/SnapTransition");
// create the main context
var mainContext = Engine.createContext();
var Engine = require("famous/core/Engine");
var Surface = require("famous/core/Surface");
var Modifier = require("famous/core/Modifier");
var Transform = require("famous/core/Transform");
var Transitionable = require("famous/transitions/Transitionable");
var WallTransition = require("famous/transitions/WallTransition");
// create the main context
var mainContext = Engine.createContext();
@AdrianRossouw
AdrianRossouw / 00readme.md
Last active August 29, 2015 14:05
werewolves.io world timer model

This is the timer model I built for the werewolves.io project a few months ago.

The entire project was built on the back of state.js and backbone.

What was interesting about this timer model, and most of the werewolves project actually, is that it formed part of
a distributed state machine. The timer state changes were streamed over websockets to each of the clients, and when
the server manipulated the timer, it would propagate to all connected browser tabs.

I also needed to be able to serialize the state to be able to set the initial data for each new load, and I also
had to make some considerations towards eventually storing the active game in something like redis, to survive