首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >vscode .vue文件格式配置 使其与webstorm设置一致

vscode .vue文件格式配置 使其与webstorm设置一致

原创
作者头像
yangdongnan
修改2020-08-04 09:55:34
1.5K0
修改2020-08-04 09:55:34
举报
文章被收录于专栏:日常记录日常记录
{
  "files.autoSave": "afterDelay",
  "editor.renderControlCharacters": true,
  "workbench.iconTheme": "material-icon-theme",
  "window.zoomLevel": 0,
  "[html]": {
    "editor.defaultFormatter": "HookyQR.beautify"
  },
  "[javascript]": {
    "editor.defaultFormatter": "vscode.typescript-language-features",
  },
  "[json]": {
    "editor.defaultFormatter": "vscode.json-language-features"
  },
  "remote.SSH.showLoginTerminal": true,
  "remote.SSH.remotePlatform": {},
  "remote.SSH.enableAzureIntegration": true,
  "sonarlint.ls.javaHome": "c:\\Users\\杨东楠\\.vscode\\extensions\\sonarsource.sonarlint_managed-jre\\jre\\jdk-11.0.7+10-jre",
  "editor.tabSize": 2,
  "editor.detectIndentation": false,
  "editor.wordWrap": "off",
  "editor.tabCompletion": "on",
  "workbench.colorTheme": "Atom One Dark",
  "editor.formatOnType": true,
  "editor.formatOnPaste": true,
  "editor.renderWhitespace": "all",
  "beautify.config": "",
  "explorer.confirmDelete": false,
  "files.associations": {
    ".vue": "html",
    ".ts": "ts",
  },
  //在文件末尾自动插入空白行
  "files.insertFinalNewline": true,
  //自定义格式化选项 tab缩进 此处设置后上面的将不生效
  "vetur.format.options.tabSize": 2,
  "vetur.format.defaultFormatter.html": "js-beautify-html",
  "vetur.format.defaultFormatterOptions": {
    "js-beautify-html": {
      //自动换行
      "wrap_attributes": "auto",
      "wrap_attributes_mode": "auto",
      //换行最大长度
      "wrap-line-length": 120,
      "wrapped_attributes_per_line": "multiple",
      "wrapped_attributes_indent": "auto",
      "wrapped_attributes_end": "auto"
    },
    "prettier": {
      //强制设置单引号
      "singleQuote": true,
      //尾部是否加分号
      "semi": true,
      "printWidth": 100,
    },
    "prettyhtml": {
      "printWidth": 100,
      "singleQuote": false,
    }
  },
  "emmet.includeLanguages": {
    "vue": "html",
  },
  "vetur.format.options.useTabs": true,
  //默认script标签缩进
  "vetur.format.scriptInitialIndent": true,
  //默认style标签缩进
  "vetur.format.styleInitialIndent": true,
  "vetur.grammar.customBlocks": {
    "docs": "md",
    "i18n": "json"
  },
}

原创声明:本文系作者授权腾讯云开发者社区发表,未经许可,不得转载。

如有侵权,请联系 cloudcommunity@tencent.com 删除。

原创声明:本文系作者授权腾讯云开发者社区发表,未经许可,不得转载。

如有侵权,请联系 cloudcommunity@tencent.com 删除。

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档