在配置 eslint 的 settings.json 时,发现下面飘颜色:
不用添加 autoFix 字段,它是默认为 true 的。
// 保存后自动修复格式 "editor.codeActionsOnSave": { "source.fixAll.eslint": true }, // 添加vue支持 "eslint.validate": [ "javascript", "javascriptreact", "vue" ]
参考:https://stackoverflow.com/questions/61316272/auto-fix-is-enabled-by-default-use-the-single-string-form