Added jshint and jscs checks to Grunt tasks.
This commit is contained in:
27
Gruntfile.js
27
Gruntfile.js
@@ -68,6 +68,29 @@ module.exports = function(grunt) {
|
||||
'dist/panel-triggers/css/panel_triggers.css' : 'src/panel-triggers/sass/panel_triggers.scss',
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
jshint: {
|
||||
source: {
|
||||
files: {
|
||||
src: ['src/**/*.js'],
|
||||
}
|
||||
},
|
||||
options: {
|
||||
jshintrc: true,
|
||||
reporter: require('jshint-stylish'),
|
||||
ignores: [
|
||||
'node_modules/*',
|
||||
'dist/*',
|
||||
]
|
||||
}
|
||||
},
|
||||
|
||||
jscs: {
|
||||
src: ['src/**/*.js'],
|
||||
options: {
|
||||
config: ".jscs.json",
|
||||
},
|
||||
}
|
||||
|
||||
});
|
||||
@@ -76,7 +99,9 @@ module.exports = function(grunt) {
|
||||
'clean',
|
||||
'copy:src_to_dist',
|
||||
'copy:pluginDef',
|
||||
'sass',
|
||||
'babel',
|
||||
'sass'
|
||||
'jshint',
|
||||
'jscs'
|
||||
]);
|
||||
};
|
||||
|
||||
@@ -32,6 +32,9 @@
|
||||
"babel-plugin-transform-es2015-modules-systemjs": "^6.5.0",
|
||||
"babel-plugin-transform-es2015-for-of": "^6.5.0",
|
||||
"babel-preset-es2015": "^6.5.0",
|
||||
"grunt-contrib-jshint": "^1.0.0",
|
||||
"grunt-jscs": "^2.8.0",
|
||||
"jshint-stylish": "^2.1.0",
|
||||
"lodash": "~4.0.0"
|
||||
},
|
||||
"homepage": "http://grafana-zabbix.org"
|
||||
|
||||
Reference in New Issue
Block a user