VScode的setting.json设置
{
"editor.renderControlCharacters": true,
"editor.renderWhitespace": "all",
// "backgroundCover.autoStatus": true,
"editor.tabSize": 2,
"files.associations": {
"*.vue": "vue"
},
"eslint.debug": true,
"eslint.format.enable": true,
"eslint.lintTask.enable": true,
"eslint.validate": ["javascript", "javascriptreact", "html", "vue"],
"eslint.run": "onSave",
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true,
"source.fixAll.stylelint": true
},
// "eslint.autoFixOnSave": true,
"search.exclude": {
"**/node_modules": true,
"**/bower_components": true,
"**/dist": true
},
"emmet.syntaxProfiles": {
"javascript": "jsx",
"vue": "html",
"vue-html": "html"
},
"git.confirmSync": false,
"editor.minimap.enabled": true,
"editor.minimap.renderCharacters": false,
"window.title": "${dirty}${activeEditorMedium}${separator}${rootName}",
"editor.codeLens": true,
//
"prettier.semi": false,
//
"prettier.singleQuote": true,
//
"javascript.format.insertSpaceBeforeFunctionParenthesis": true,
//
"vetur.format.defaultFormatter.html": "js-beautify-html",
//
"vetur.format.defaultFormatter.js": "vscode-typescript",
"vetur.format.defaultFormatterOptions": {
"js-beautify-html": {
"wrap_attributes": "auto"
//
}
},
"px-to-rem.number-of-decimals-digits": 6,
"px-to-rem.px-per-rem": 37,
// vscode默认启用了根据文件类型自动设置tabsize的选项
"editor.detectIndentation": false,
//
"editor.formatOnSave": true,
"editor.formatOnType": true,
"vetur.validation.template": false, //关闭vetur标签闭合检查(用于解决iview标签报错)
"extensions.autoUpdate": false,
"update.mode": "none",
"git.autofetch": true,
"editor.fontLigatures": false,
"task.problemMatchers.neverPrompt": false,
"gitlens.advanced.messages": {
"suppressLineUncommittedWarning": true
},
"explorer.confirmDelete": false,
"javascript.updateImportsOnFileMove.enabled": "never",
"htmltagwrap.tag": "div",
"gitlens.gitCommands.closeOnFocusOut": true,
"[vue]": {
"editor.defaultFormatter": "octref.vetur"
},
"[jsonc]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"bracketPairColorizer.depreciation-notice": false,
"editor.quickSuggestions": {
"other": true,
"comments": true,
"strings": true
},
"editor.wordWrap": "on",
"search.followSymlinks": false,
"editor.unicodeHighlight.allowedLocales": {
"zh-hant": true
},
"workbench.startupEditor": "none",
"security.workspace.trust.untrustedFiles": "open",
"terminal.integrated.shell.windows": "C:/Windows/System32/cmd.exe",
"editor.bracketPairColorization.enabled": true,
"editor.guides.bracketPairs": "active"
}