在setting.json中加入如下内容

{
  "eslint.autoFixOnSave": true,
  "eslint.validate": [
    "javascript",
    "javascriptreact",
    {
      "language": "html",
      "autoFix": true
    },
    {
      "language": "vue",
      "autoFix": true
    }
  ]
}

参考:http://www.ptbird.cn/vscode-autosave-eslint-support-vue.html

相关文章:

  • 2021-10-03
  • 2022-02-24
  • 2022-12-23
  • 2021-09-30
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-05-28
  • 2022-12-23
  • 2021-08-29
  • 2022-12-23
  • 2021-11-26
  • 2022-12-23
相关资源
相似解决方案