From e52d16defa81dbbd8d3d14115a9bb3553ad85de7 Mon Sep 17 00:00:00 2001 From: Pavel Reznikov Date: Fri, 19 Feb 2016 14:31:06 -0800 Subject: [PATCH] add jshint to grunt tasks --- Gruntfile.js | 7 ++++++- package.json | 5 +++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/Gruntfile.js b/Gruntfile.js index 1ae9dd9..fe77181 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -4,6 +4,7 @@ module.exports = function (grunt) { grunt.loadNpmTasks('grunt-contrib-copy'); grunt.loadNpmTasks('grunt-contrib-uglify'); grunt.loadNpmTasks('grunt-doctoc'); + grunt.loadNpmTasks('grunt-contrib-jshint'); grunt.initConfig({ sass: { @@ -55,8 +56,12 @@ module.exports = function (grunt) { readme: { target: "./README.md" } + }, + + jshint: { + all: ['src/*.js'] } }); - grunt.registerTask('default', ['sass', 'cssmin', 'copy', 'uglify', 'doctoc']); + grunt.registerTask('default', ['sass', 'cssmin', 'copy', 'uglify', 'doctoc', 'jshint']); }; diff --git a/package.json b/package.json index c2f81de..ca833af 100644 --- a/package.json +++ b/package.json @@ -24,8 +24,9 @@ "grunt": "^0.4.5", "grunt-contrib-copy": "^0.8.2", "grunt-contrib-cssmin": "^0.14.0", + "grunt-contrib-jshint": "^1.0.0", "grunt-contrib-uglify": "^0.10.1", - "grunt-sass": "^1.1.0", - "grunt-doctoc": "^0.1.1" + "grunt-doctoc": "^0.1.1", + "grunt-sass": "^1.1.0" } }