Getting Started with ESLint
ESLint is a tool for identifying and reporting on patterns found in ECMAScript/JavaScript code, with the goal of making code more consistent and avoiding bugs. In many ways, it is similar to JSLint and JSHint with a few exceptions: ESLint uses Espree for JavaScript parsing. ESLint uses an AST to evaluate patterns in code. ESLint is completely pluggable, every single rule is a plugin and you can add more at runtime. Installation and Usage Prerequisites: Node.js ( ^10.12.0 , or >=12.0.0 ) built with SSL support. (If you are using an official Node.js distribution, SSL is always built in.) You can install ESLint using npm or yarn: npm install eslint --save-dev # or yarn add eslint --dev You should then set up a configuration file: $ npx eslint --init After that, you can run ESLint on any file or directory like this: $ npx eslint yourfile.js It is also possible to install ESLint globally rather than locally (using npm install eslint --global )....