Skip to content

Instantly share code, notes, and snippets.

@raphaelgabbarelli
Created December 26, 2014 16:19
Show Gist options
  • Save raphaelgabbarelli/517e6b4ce39fdf20731f to your computer and use it in GitHub Desktop.
Save raphaelgabbarelli/517e6b4ce39fdf20731f to your computer and use it in GitHub Desktop.
registering a type
this.add = function(key, dependency){
for(var i = 0; i < self.dependencies.length; i++){
if(self.dependencies[i].key === key){
return;
}
}
self.dependencies.push({key : key, dependency : dependency});
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment