Big changes

This starts the use of ECMAScript 6 (ES6/Harmony) and the mediator pattern.