Gobliins
Gobliins

Reputation: 4026

ESLint in Eclipse display errors as warn or info

I am using ESLint in Eclipse and the hints provided by ESLint are displayed as Errors (But they are only code improvement hints and not errors).

Is there a way i can configure ESLint / Eclipse to display those Errors as Warning or Info instead as Errors?

Upvotes: 0

Views: 510

Answers (1)

btmills
btmills

Reputation: 4542

ESLint automatically looks for .eslintrc.json files. You can run eslint --init to have ESLint create a configuration file for you, or you can create one manually. Here's an example modified from the Getting Started guide:

{
    "rules": {
        "eqeqeq": "off",
        "quotes": ["warn", "double"],
        "semi": ["error", "always"]
    }
}

In this example, the eqeqeq rule will be disabled, quotes will show warnings, and semi will give you errors.

Upvotes: 1

Related Questions