Friday, January 20, 2017

How to integrate ESLint with Sublime Text 3

In order to evaluate your code using eslint, you first need to have it installed in your system.

npm install -g eslint

To test it, you can simple execute eslit <filename>.js from the command line.

1. Now, we can proceed to install the Sublime Text pluging by going through Preferences -> Package Control -> Install Package

2. Select "SublimeLinter-contrib-eslint".


3. And, finally just copy a .eslintrc file (with the rules definitions) to the root path of your project.


or generate it by typing eslint --init


And that's it!, now you will be highlighted for every syntax error detected in your files (based on your .eslintrc configuration) while editing them.