64

I have ESlint configured with vscode using the plugin, now I'm wondering is there some way I can stop ESlint from showing me the parser/syntax errors, so I can instead view the syntax errors that the Salsa language service provides by default.

9 Answers 9

81

Update: please refer this updated answer

Open up settings.json and add the property: "eslint.enable": false

Check: https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint

4
  • 2
    is there any way to disable just few rules rather than the whole eslint?
    – Siraj Alam
    Commented Jun 15, 2020 at 15:06
  • @SirajAlam I don't think you can do that with VS Code settings, you would have to configure your .eslintrc file to disable specific rules. eslint.org/docs/user-guide/configuring Commented Jun 17, 2020 at 13:13
  • 3
    this warning is shown This setting is deprecated. Disable ESLint using the extensions viewlet. Commented Dec 9, 2020 at 16:05
  • 1
    @AwaisNasir definately agree. Only melMass updated their answer stackoverflow.com/a/65268582/1906088 and it needs to be appreciated cause it's the only one up to date for this one at the moment.
    – pt12lol
    Commented Jan 28, 2021 at 7:57
33

The old:

"eslint.enable": false

Is deprecated, now you need to use the builtin VSCode mechanism for disabling extensions:

vscode-screenshot

29

In order to disable ESLint only for a specific repo (instead of disabling it globally). Create .vscode folder in your project root and there create a settings.json then add the following config:

{
    "eslint.enable": false
}

Maybe after this setting you should consider adding the .vscode/settings.json line to your .gitignore file too, but it is based on your dev team's preference. }

Additionally if you'd like to ignore only some vendor/3PP .js files only then you should consider creating an .eslintignore file. Read more about this here.

2
  • 1
    People coming here in 2021 and later: this solution is now deprecated [or so said the warning message I got]
    – Ghadir
    Commented Jul 23, 2021 at 23:27
  • This solution may be deprecated, but at least works, contrary to others.
    – sba
    Commented Mar 11, 2022 at 16:58
25

go to File => Preferences => Settings

enter image description here

go to Extensions=>ESLint

enter image description here

Uncheck the EsLint:Enable

enter image description here

6

In VSCode, go to

File >> preferences >> settings

Type 'eslint quiet' in the search bar and click the check box for quiet mode.

In quiet mode, eslint would ignore basic errors. This should work for many VSCode users as at March 4, 2022. You're welcome!

1
  • To be more precise, the Quiet setting ignores warnings in the VSC UI.
    – Seth Falco
    Commented Oct 8, 2022 at 19:14
3
1-) npm install -g eslint
2-) Open up settings.json and add the property: "eslint.enable": false
3

If you want to disable eslint errors in VSCode, Go to settings.json and disable all rules like this

   "eslint.rules.customizations": [
    {
        "rule": "*",
        "severity": "off"
    }
]

This will disable all the eslint rules for you. If you want to disable a particular rule like "@typescript-eslint/no-this-alias", you can do the following

"eslint.rules.customizations": [
        {
            "rule": "@typescript-eslint/no-this-alias",
            "severity": "off"
        }
    ]
1
  • 2
    This is the correct answer in case user doesn't want to disable ESlint totally, but wants to keep ESlint formatting while saving file, for example.
    – Frimlik
    Commented Nov 9, 2023 at 6:41
1

Please open settings.json file and edit the configuration as below:

"eslint.enable": false

Hope this helps.

2
  • @SethFalco Are you sure it fixes automatically the eslint errors ? I do not have that behavior on my side
    – snoob dogg
    Commented Feb 15, 2023 at 15:25
  • The answer has changed since I commented on it. The original version of this (see edit history) had an entirely different answer. I'll delete my comment to avoid confusion.
    – Seth Falco
    Commented Feb 15, 2023 at 15:29
0

I don't understand why some answers states that eslint.enable is depracted. it works for me. in my WorkSpace settings (JSON), I add the following configuration and eslint errors disapears

{
    ...

    "settings": {
        "eslint.enable": false
    },
}

Not the answer you're looking for? Browse other questions tagged or ask your own question.