add jshint plugin and fix all the linting errors of js code