Add JSHint and fix all warnings