Reworked js and partial files to follow a modular pattern.