5.拷贝到settings.json
{
// tab 大小为2个空格
"editor.tabSize": 2,
// 100 列后换行
"editor.wordWrapColumn": 150,
// 保存时格式化
"editor.formatOnSave": true,
//让prettier使用eslint的代码格式进行校验
"prettier.eslintIntegration": true,
// 开启 vscode 文件路径导航
"breadcrumbs.enabled": true,
// 让函数(名)和后面的括号之间加个空格
"javascript.format.insertSpaceBeforeFunctionParenthesis": true,
// 格式化.vue中html
"vetur.format.defaultFormatter.html": "js-beautify-html",
//让vue中的js按编辑器自带的ts格式进行格式化
"vetur.format.defaultFormatter.js": "vscode-typescript",
// prettier 设置语句末尾不加分号
"prettier.semi": false,
// prettier 设置强制单引号
// "prettier.singleQuote": false,
// 选择 vue 文件中 template 的格式化工具
"vetur.format.defaultFormatter.html": "prettyhtml",
// 显示 markdown 中英文切换时产生的特殊字符
"editor.renderControlCharacters": true,
// 设置 eslint 保存时自动修复
"eslint.autoFixOnSave": true,
// eslint 检测文件类型
"eslint.validate": [
"javascript",
"javascriptreact",
{
"language": "html",
"autoFix": true
},
{
"language": "vue",
"autoFix": true
}
],
// vetur 的自定义设置
"vetur.format.defaultFormatterOptions": {
"prettier": {
"singleQuote": false,
"semi": true
}
},
"workbench.tree.indent": 20,
"window.zoomLevel": 1,
"javascript.updateImportsOnFileMove.enabled": "always",
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
},
"workbench.statusBar.visible": false,
"tabnine.experimentalAutoImports": true,
"files.associations": {},
"editor.semanticTokenColorCustomizations": null,
"gitlens.advanced.blame.customArguments": [],
"gitlens.views.repositories.showBranchComparison": null,
"gitlens.gitCommands.closeOnFocusOut": true,
"gitlens.statusBar.dateFormat": "",
"workbench.colorCustomizations": {
"activityBarBadge.background": "#FF7042",
"activityBar.activeBorder": "#FF7042",
"list.activeSelectionForeground": "#FF7042",
"list.inactiveSelectionForeground": "#FF7042",
"list.highlightForeground": "#FF7042",
"scrollbarSlider.activeBackground": "#FF704250",
"editorSuggestWidget.highlightForeground": "#FF7042",
"textLink.foreground": "#FF7042",
"progressBar.background": "#FF7042",
"pickerGroup.foreground": "#FF7042",
"tab.activeBorder": "#FF7042",
"notificationLink.foreground": "#FF7042",
"editorWidget.resizeBorder": "#FF7042",
"editorWidget.border": "#FF7042",
"settings.modifiedItemIndicator": "#FF7042",
"settings.headerForeground": "#FF7042",
"panelTitle.activeBorder": "#FF7042",
"breadcrumb.activeSelectionForeground": "#FF7042",
"menu.selectionForeground": "#FF7042",
"menubar.selectionForeground": "#FF7042",
"editor.findMatchBorder": "#FF7042",
"selection.background": "#FF704240",
"statusBarItem.remoteBackground": "#FF7042"
},
"materialTheme.accent": "Orange",
"gitlens.gitCommands.skipConfirmations": [
"fetch:command",
"switch:command"
],
"gitlens.blame.dateFormat": "",
"editor.fontLigatures": null,
"explorer.confirmDelete": false
}