added layer dependencies
added ninejs support
fixed some bugs that were affecting me