vscode设置setting.json文件适用vue和eslint

{
    "editor.cursorBlinking": "smooth",
    "editor.cursorStyle": "block",
    "workbench.iconTheme": "vscode-icons",
    "editor.fontFamily": "Consolas,Monospace",
    "workbench.colorTheme": "Dracula",
    "editor.wordWrap": "on",
    "vsicons.dontShowNewVersionMessage": true,
    "editor.cursorStyle": "line", //光标为细竖线
    "editor.tabSize": 2,  //缩进2个空格
    "vetur.format.defaultFormatterOptions": {
        "prettier": {
          "semi": false, //去掉末尾分号
          "singleQuote": true  //将所有双引号改为单引号
        }
      },
    "javascript.format.insertSpaceBeforeFunctionParenthesis": true,  //在方括号之间插入空格
    "vetur.format.defaultFormatter.js": "vscode-typescript",
    //配置下vscode支持vue语言
    "eslint.validate": [
        "javascript",
        "javascriptreact",
        "html",
          {
            "language": "vue",
            "autoFix": true
          }
      ]   
}

 

你可能感兴趣的:(VScode)