Format JavaScript functions as per styleguide

- Removes space before function declaration parentheses.
- Adds space before function left brace.

See https://github.com/moneyadviceservice/javascript#functions
Format JavaScript comments as per styleguide

See https://github.com/moneyadviceservice/javascript#comments
Format JavaScript whitespace as per styleguide

See https://github.com/moneyadviceservice/javascript#whitespace
Format JavaScript variables as per styleguide

See https://github.com/moneyadviceservice/javascript#variables
Format JavaScript properties as per styleguide