New Release: 2.0.0

WARNING: This release introduces backwards incompatible changes.

JSHint 2.0.0 is out! This version hits a pretty big milestone for the project: this is the first JSHint release for which I'm not the biggest contributor. I personally believe this fact validates JSHint as a successful open source project. And I'm extremely thankful to all you who file bug reports and send patches—you're all awesome.

EcmaScript 5

The first and foremost: starting with this version JSHint will assume ES5 as the default environment. Before, JSHint was checking all the code per ES3 specification with an option to enable ES5 mode. Now ES5 mode is the default mode and if you want to check your code against the ES3 specification (useful when developing for super old browsers such as Internet Explorer 6) you will have to use es3:true.

Special thanks to Rick Waldron for championing this change.

Partial support for Mozilla JavaScript extensions and ES6

Thanks to our newest core contributor, Bernard Pratz, JSHint now has partial support for Mozilla JavaScript extensions (moz option) and ES6 (esnext option):

  • Destructuring assignment
  • const
  • let blocks and expressions
  • Generators and iterators
  • List comprehension
  • Try/catch filters and multiple catch blocks
  • Concise method declaration
  • for ... of loops
  • Fat arrows

We have more patches in queue that add support for classes and other nifty ES6 things. Stay tuned!


  • JSHint now looks for .jshintrc in the directory being linted. (#833)
  • Various cross-platform fixes for our Node CLI module.
  • New public method for the CLI export that allows third-parties to hook into the file resolution logic. (#741)


  • For non-Node system we upgraded to the latest version of Browserify. This resolves some performance issues we had with Rhino.
  • Added SVG globals to the browser environment.
  • Option smarttabs now ignores mixed tabs and spaces within single- and multi-line comments.
  • Added a new pragma to unignore a warning:

    /jshint -W096 /

    // All warnings about keys producing unexpected results will // be ignored here.

    /jshint +W096 /

    // But not here.

  • JSHint now ignores unrecognized JSLint options.

  • Fixed a bug where indent:false was triggering indentation warnings. (#1035)
  • Fixed a regression bug where unused was not behaving correctly. (#996)
  • Plus lots and lots of other, smaller bug fixes.

New rapid release schedule

And last but not least: starting with this version, I'm switching JSHint to a more rapid release schedule. This simply means that I will be publishing new versions of JSHint more often. I will try my best to follow semver recommendations and ship working software. But as our license says, no guarantees.

Thanks to Bernarnd Pratz, Michelle Steigerwalt, Yuya Tanaka, Matthew Flaschen, Juan Pablo Buritica, Matt Cheely, Steve Mosley, Stephen Sorensen, Rick Waldron, Hugues Malphettes, Jeff Thompson, xzyfer, Lee Leathers, croensch, Steven Benner, James Allardice, Sindre Sorhus, Jordan Harband, Stuart Knightley and Kevin Locke for sending patches!