Visual Studio Code 首选项设置
{
"editor.suggestSelection": "first",
"vsintellicode.modify.editor.suggestSelection": "automaticallyOverrodeDefaultValue",
"fileheader.configObj": {
"createFileTime": true,
"language": {
"languagetest": {
"head": "/$$",
"middle": " $ @",
"end": " $/"
}
},
"autoAdd": true,
"autoAddLine": 100,
"autoAlready": true,
"annotationStr": {
"head": "/*",
"middle": " * @",
"end": " */",
"use": false
},
"headInsertLine": {
"php": 2,
"sh": 2
},
"beforeAnnotation": {
"文件后缀": "该文件后缀的头部注释之前添加某些内容"
},
"afterAnnotation": {
"文件后缀": "该文件后缀的头部注释之后添加某些内容"
},
"specialOptions": {
"特殊字段": "自定义比如LastEditTime/LastEditors"
},
"switch": {
"newlineAddAnnotation": true
},
"supportAutoLanguage": [],
"prohibitAutoAdd": ["json"],
"prohibitItemAutoAdd": [
"项目的全称, 整个项目禁止自动添加头部注释, 可以使用快捷键添加"
],
"moveCursor": true,
"dateFormat": "YYYY-MM-DD HH:mm:ss",
"atSymbol": ["@", "@"],
"atSymbolObj": {
"文件后缀": ["头部注释@符号", "函数注释@符号"]
},
"colon": [": ", ": "],
"colonObj": {
"文件后缀": ["头部注释冒号", "函数注释冒号"]
},
"filePathColon": "路径分隔符替换",
"showErrorMessage": false,
"writeLog": false,
"wideSame": false,
"wideNum": 13,
"functionWideNum": 0,
"CheckFileChange": false,
"createHeader": true,
"useWorker": false,
"designAddHead": false,
"headDesignName": "random",
"headDesign": false,
"cursorModeInternal": false
},
// 打开文件不覆盖
"workbench.editor.enablePreview": false,
// 关闭rg.exe进程,防止VSCode启动带有node_modules的项目的时候很卡的问题
"search.followSymlinks": false,
// 关闭快速预览
"editor.minimap.enabled": false,
// 头部注释 Crtl + Alt + I
"fileheader.customMade": {
// 文件内容描述
"Description": "",
// 编辑人
"Author": "工号/姓名",
// 时间
"Date": "Do not edit",
"LastEditTime": "Do not edit",
"LastEditors": "工号/姓名"
},
// 函数注释 Crtl + Alt + T
"fileheader.cursorMode": {
// 函数说明
"description": "",
// 参数
"param": "",
// 返回值
"return": ""
},
// 每次保存的时候将代码按eslint格式进行修复
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
},
// 保存时是否自动格式化
"editor.formatOnSave": true,
// vscode默认启用了根据文件类型自动设置tabsize的选项
"editor.detectIndentation": false,
// 视图每行最大字符数
"editor.wordWrapColumn": 150,
// 视图自动换行控制(视觉上折行,不增加代码行数),超出wordWrapColumn设置的值折行
"editor.wordWrap": "wordWrapColumn",
// 辅助线
"editor.renderIndentGuides": false,
// 让vue中的js按编辑器自带的ts格式进行格式化
"vetur.format.defaultFormatter.js": "vscode-typescript",
// 函数前添加空格
"javascript.format.insertSpaceBeforeFunctionParenthesis": true,
// 定义匿名函数的函数关键字后面的空格处理
"javascript.format.insertSpaceAfterFunctionKeywordForAnonymousFunctions": false,
// 按用户自身习惯选择
"vetur.format.defaultFormatter.html": "prettyhtml",
// vue组件中html代码格式化样式
"vetur.format.defaultFormatterOptions": {
"js-beautify-html": {
"wrap_attributes": "force-expand-multiline"
}
},
"[vue]": {
"editor.defaultFormatter": "octref.vetur"
},
"[javascript]": {
"editor.defaultFormatter": "vscode.typescript-language-features"
},
"[less]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[json]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[jsonc]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[html]": {
"editor.defaultFormatter": "HookyQR.beautify"
},
"terminal.integrated.tabs.enabled": true,
"workbench.iconTheme": "vscode-icons",
"[css]": {
"editor.defaultFormatter": "michelemelluso.code-beautifier"
},
"editor.tabSize": 2,
"workbench.colorTheme": "Monokai",
"workbench.startupEditor": "none",
"security.workspace.trust.untrustedFiles": "open"
}