11

Premise: When I use Visual Studio Code I want linting on save and I like intellisense.

Nonetheless, I'm annoyed to no end by linting (aka error and warning messages in the form of "[ts/jshint]: here you're missing a semicolon") while I'm typing. They are absolutely useless (I never watch them), distracting, with all that flashy things appearing and disappearing at the bottom of the screen, and yesterday, when my pc was already slowed down for other reasons, it reduced the typing to a crawl.

Since I couldn't find a way to disable linting on typing, I went in the settings and disabled mostly of the TypeScript controls (since they were the worst offenders, useless to me, because I very rarely use a .ts, and anyway I use Flow + jshint, which are more than enough). And, for some magical reasons, it even seemed to disable the linting while typing, leaving active only the one on save.

But then today, when I opened Visual Studio Code, the linting while typing restarted. The (TypeScript) errors are very few now, but there are a few still produced by jshint. Flow, luckily, works as intended and only on save.

So, is there a way to disable the linting while typing, leaving active both intellisense, code completion suggestion and the linting on save?

I have enabled the following extensions: HTML CSS Support 0.2.0, HTML to JavaScript string 0.0.6, JavaScript Booster 0.10.2, jshint 0.10.20, Sorting HTML and Jade attributes 2.1.0, Todo Tree 0.0.116, and vscode-flow-ide 1.2.0.

(Momentarily, I disabled intellisense, to see if it fixed the problem. It didn't.)

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
DrHell
  • 461
  • 3
  • 17
  • Somewhat related: [How can I easily toggle display of problem underlining in VS Code editor panels?](/q/74753185/11107541) – starball Mar 07 '23 at 22:09

1 Answers1

2

As at Feb 2023, the jshint extension is deprecated:

This extension is deprecated. Use the ESLint extension instead.

ESLint has a setting that should achieve this:

eslint.run - run the linter onSave or onType, default is onType.

Zaq
  • 1,071
  • 2
  • 10
  • 19