• .vscode/setting.json


    {
        // editor
        "editor.formatOnSave": true,
        "editor.codeActionsOnSave": {
          "source.fixAll.eslint": true
        },
        "editor.tabSize": 2,
        "editor.insertSpaces": true,
        "editor.detectIndentation": true,
        "editor.defaultFormatter": "vscode.typescript-language-features",
        "[javascript]": {
          "editor.defaultFormatter": "vscode.typescript-language-features"
        },
        "[typescript]": {
          "editor.defaultFormatter": "vscode.typescript-language-features"
        },
        "[vue]": {
          "editor.defaultFormatter": "octref.vetur"
        },
        "[css]": {
          "editor.defaultFormatter": "vscode.css-language-features"
        },
        "[html]": {
          "editor.defaultFormatter": "vscode.html-language-features"
        },
        "[json]": {
          "editor.defaultFormatter": "vscode.json-language-features"
        },
        "[less]": {
          "editor.defaultFormatter": "esbenp.prettier-vscode"
        },
      
        //javascript
        "javascript.format.insertSpaceBeforeFunctionParenthesis": true,
        "javascript.format.semicolons": "insert", // 要设置 vscode.typescript-language-features
      
        //eslint
        "eslint.format.enable": false,
        "eslint.validate": [
          "javascript",
          "javascriptreact",
          "vue",
          "typescript",
          "typescriptreact"
        ],
      
        //vetur
        "vetur.format.defaultFormatter.js": "vscode-typescript",
        "vetur.format.defaultFormatter.html": "js-beautify-html",
        "vetur.format.defaultFormatterOptions": {
          "js-beautify-html": {
            "wrap_attributes": "force-aligned"
          }
        },
        "vetur.validation.template": false
      }
      
    

    改.gitignore文件:
    步骤一:
    删除原来的.vscode
    步骤二:
    在文件末尾新增
    .vscode/*
    !.vscode/settings.json

  • 相关阅读:
    【转】web测试容易被遗忘的地方
    212
    将博客搬至CSDN
    关于Navicat连接虚拟机windows virsual pc 的mysql
    Java匿名内部类继承类和实现接口
    [转]文本输入框特效大集合
    jquery操作select
    HashMap和Hashtable的区别
    Struts2+Spring+hibernate最新版本官方下载地址
    Java
  • 原文地址:https://www.cnblogs.com/pengchenggang/p/15891779.html
Copyright © 2020-2023  润新知