Restructure js files to more logic and less everything every where.
Removing old index
Merge pull request #3 from Mutmatt/dev

Dev