Futz with JSHint
First draft of client-side JS (no tests yet!)