Added config.js, restructured js, added remaining frontpage event handlers