vue3 VsCode的保存代码格式设定
Posted 是小橙鸭丶
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了vue3 VsCode的保存代码格式设定相关的知识,希望对你有一定的参考价值。
"typescript.tsdk": "./node_modules/typescript/lib",
"volar.tsPlugin": true,
"volar.tsPluginStatus": false,
"npm.packageManager": "pnpm",
"editor.tabSize": 2,
"editor.defaultFormatter": "esbenp.prettier-vscode",
"files.eol": "\\n",
"search.exclude":
"**/node_modules": true,
"**/*.log": true,
"**/*.log*": true,
"**/bower_components": true,
"**/dist": true,
"**/elehukouben": true,
"**/.git": true,
"**/.gitignore": true,
"**/.svn": true,
"**/.DS_Store": true,
"**/.idea": true,
"**/.vscode": false,
"**/yarn.lock": true,
"**/tmp": true,
"out": true,
"dist": true,
"node_modules": true,
"CHANGELOG.md": true,
"examples": true,
"res": true,
"screenshots": true,
"yarn-error.log": true,
"**/.yarn": true
,
"files.exclude":
"**/.cache": true,
"**/.editorconfig": true,
"**/.eslintcache": true,
"**/bower_components": true,
"**/.idea": true,
"**/tmp": true,
"**/.git": true,
"**/.svn": true,
"**/.hg": true,
"**/CVS": true,
"**/.DS_Store": true
,
"files.watcherExclude":
"**/.git/objects/**": true,
"**/.git/subtree-cache/**": true,
"**/.vscode/**": true,
"**/node_modules/**": true,
"**/tmp/**": true,
"**/bower_components/**": true,
"**/dist/**": true,
"**/yarn.lock": true
,
"stylelint.enable": true,
"stylelint.packageManager": "yarn",
"path-intellisense.mappings":
"/@/": "$workspaceRoot/src"
,
"[javascriptreact]":
"editor.defaultFormatter": "esbenp.prettier-vscode"
,
"[typescript]":
"editor.defaultFormatter": "esbenp.prettier-vscode"
,
"[typescriptreact]":
"editor.defaultFormatter": "esbenp.prettier-vscode"
,
"[html]":
"editor.defaultFormatter": "esbenp.prettier-vscode"
,
"[css]":
"editor.defaultFormatter": "esbenp.prettier-vscode"
,
"[less]":
"editor.defaultFormatter": "esbenp.prettier-vscode"
,
"[scss]":
"editor.defaultFormatter": "esbenp.prettier-vscode"
,
"[markdown]":
"editor.defaultFormatter": "esbenp.prettier-vscode"
,
"editor.codeActionsOnSave":
"source.fixAll.eslint": true
,
"[vue]":
"editor.codeActionsOnSave":
"source.fixAll.eslint": false
,
"i18n-ally.localesPaths": ["src/locales/lang"],
"i18n-ally.keystyle": "nested",
"i18n-ally.sortKeys": true,
"i18n-ally.namespace": true,
"i18n-ally.pathMatcher": "locale/namespaces.ext",
"i18n-ally.enabledParsers": ["ts"],
"i18n-ally.sourceLanguage": "en",
"i18n-ally.displayLanguage": "zh-CN",
"i18n-ally.enabledFrameworks": ["vue", "react"],
"cSpell.words": [
"windi",
"browserslist",
"tailwindcss",
"esnext",
"antv",
"tinymce",
"qrcode",
"sider",
"pinia",
"sider",
"nprogress",
"INTLIFY",
"stylelint",
"esno",
"vitejs",
"sortablejs",
"mockjs",
"codemirror",
"iconify",
"commitlint",
"vditor",
"echarts",
"cropperjs",
"logicflow",
"vueuse",
"zxcvbn",
"lintstagedrc",
"brotli",
"tailwindcss",
"sider",
"pnpm",
"antd"
]
打开VsCode,按键ctrl+shift+p,输入settings,打开settings.json,输入以上代码即可,关闭vscode重新打开即可使用
以上是关于vue3 VsCode的保存代码格式设定的主要内容,如果未能解决你的问题,请参考以下文章
VScode设置vue文件中保存自动格式化代码以及settings.json文件的配置。
vue-cli4.5 搭建( vue3+ TypeScript + ant design2)环境 及 VSCode 代码自动格式化配置