A stylish summary reporter for jshint

License: MIT

Language: JavaScript

Keywords: gulp, gulp-plugin, javascript, js, jshint, jshint-stylish, lint, linter

npm Version Build Status Coverage Status Dependency Status devDependency Status Code Climate Codacy Badge Greenkeeper badge


A stylish summary reporter for jshint. Best used in combination with jshint-stylish.

Brought on by this Stack Overflow question.


Default output with jshint (in combination with jshint-stylish):

Default output with gulp-jshint (in combination with jshint-stylish):


npm install --save-dev jshint-stylish-summary


With jshint

$ jshint --reporter=node_modules/jshint-stylish-summary src/js/*.js

Since jshint's CLI doesn't currently support multiple reporters it is necessary to create a wrapper reporter if jshint-stylish-summary should be used in combination with another reporter.

To use jshint-stylish-summary with, e.g., jshint-stylish, create a file reporter.js:

module.exports = {
  reporter: function(result, config, options) {
    require('jshint-stylish').reporter(result, config, options);
    require('jshint-stylish-summary').reporter(result, config, options);

Then pass this file to jshint:

$ jshint --reporter=reporter.js src/js/*.js

With gulp-jshint

Since jshint-stylish-summary needs to collect information about all files passing through the stream before it can log the results, it is not compatible with gulp-jshint's reporter() interface.

Instead use the collect() and summarize() functions that jshint-stylish-summary provides:

var jshintSummary = require('jshint-stylish-summary');

gulp.task('lint', function() {
  return gulp.src('src/**/*.js')
    .on('end', jshintSummary.summarize());

See the API documentation for a complete overview of all available functions and options.



Project Statistics

Sourcerank 6
Repository Size 273 KB
Stars 1
Forks 0
Watchers 1
Open issues 0
Dependencies 201
Contributors 1
Tags 5
Last updated
Last pushed

Top Contributors See all

Sven Schoenung

Packages Referencing this Repo

A stylish summary reporter for jshint
Latest release 1.0.0 - Updated - 1 stars

Recent Tags See all

v1.0.0 July 20, 2018
v0.1.2 April 13, 2016
v0.1.1 March 28, 2016
v0.1.0 March 24, 2016
v0.0.1 March 23, 2016

Something wrong with this page? Make a suggestion

Last synced: 2018-08-06 20:37:51 UTC

Login to resync this repository