Consolidated code and documentation

Consolidated code structure, updated and added code documentation to allow generating a proper documentation using JSDuck.
Is that really worth a note? That is what I remember our code architect telling us and I have done it like that always.