vscode 2023格式化vue文件设置

//  通用设置
{
  "editor.bracketPairColorization.enabled": true,
  "editor.guides.bracketPairs": "active",
  "editor.formatOnSave": true,
  "editor.defaultFormatter": "esbenp.prettier-vscode",
  "editor.mouseWheelZoom": true,
  "editor.snippetSuggestions": "top",
  // 全局格式化
  "prettier.semi": false,
  "prettier.printWidth": 120,
  "prettier.trailingComma": "none",
  "prettier.singleQuote": true,
  "prettier.arrowParens": "avoid",
  // 软件界面
  "workbench.sideBar.location": "left",
  "workbench.productIconTheme": "fluent-icons",
  "workbench.startupEditor": "none",
  "workbench.layoutControl.enabled": false,
  "workbench.iconTheme": "material-icon-theme-wechat",
  "window.commandCenter": false,
  "window.zoomLevel": 1,
  "breadcrumbs.enabled": true,
  "workbench.colorTheme": "Default Dark+",
  // git
  "git.enableSmartCommit": true,
  "git.confirmSync": false,
  // 小程序格式化,高亮
  "files.associations": {
    "*.cjson": "jsonc",
    "*.wxss": "css",
    "*.wxs": "javascript"
  },
  "emmet.includeLanguages": {
    "wxml": "html"
  },
  // AI
  "codeium.enableCodeLens": false,
  "codeium.enableConfig": {
    "*": true,
    "properties": true
  }
  // 自定义设置
}

// vetur格式化
// "vetur.format.defaultFormatter.html": "js-beautify-html",
// #vue组件中html代码格式化样式
// "vetur.format.defaultFormatterOptions": {
//   "js-beautify-html": {
//     "wrap_attributes": "force-aligned" // 属性分行对齐
//     //  "wrap_attributes": "auto" // 属性在一行显示
//     // "wrap_attributes": "force",
//     // "wrap_attributes": "force-aligned",
//     // "wrap_attributes": "force-expand-multiline"
//   }
// }

// prettier格式化
// 配置项文档:https://prettier.io/docs/en/configuration.html
// .prettierrc
// {
//   trailingComma: 'none',
//   singleQuote: true,
//   semi: false,
//   arrowParens: 'avoid',
//   printWidth: 120
// }


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值