30
15

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

VSCodeのESLintのautofixがうまく動いてなかったので設定を変えた

Posted at

Screenshot from 2019-12-19 08-29-33.png

The setting is deprecated. Use editor.codeActionsOnSave instead with a source.fixAll.eslint member.

とエラーが表示されていたので下記のように変えたら動いた。

  "editor.formatOnSave": false,
  "editor.codeActionsOnSave": {
    "source.fixAll.eslint": true,
    "source.fixAll.tslint": true,
    "source.fixAll": true
  },
  "eslint.validate": [
    "javascript",
    "javascriptreact",
    "typescript",
    "typescriptreact"
  ],

eslint.validateautoFix: true がデフォルトになったようだ。

別のPCだと同じ設定でも動いてた気がするので、これがすべての環境での解決策になるのかは怪しいかもしれない。

30
15
2

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
30
15

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?