24 Mar 2014

JSLint now supports .jslintrc

I have just updated jslint too version 0.9.0 and it now supports .jslintrc config files.

What does that mean?

Before you had to add specific jslint configuration inside every single file in your project like this

/*global $, atom*/
/*jslint indent: 2*/

But now you can add a .jslintrc file in your project root and the configuration will apply to every JavaScript file in that project.

{
  "indent": 2,
  "predef": {
    "$": true,
    "atom": true
  }
}

For more on jslint configuration see the official documentation.