Skip to content

Instantly share code, notes, and snippets.

@natemcmaster natemcmaster/CrappyBank.js

Last active Aug 29, 2015
What would you like to do?
Injector syntax
/// Config.js
function CrappyBank(data){
function GameBoard(data,$Bank,$Traker){ = $Bank(data);
this.players = $Traker(data);
Injector.create = function(name){
dep = registered function for name
for all dollar sign args of dep.constructor:
arg = new Injector.create(arg)
function MockBank(data){
function TrackerImpl(data,name,$Player){
this.player= $Player(name); data;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.