|
@@ -1,14 +1,7 @@
|
|
|
{
|
|
{
|
|
|
// 默认格式化工具选择prettier
|
|
// 默认格式化工具选择prettier
|
|
|
"editor.defaultFormatter": "esbenp.prettier-vscode",
|
|
"editor.defaultFormatter": "esbenp.prettier-vscode",
|
|
|
- // // 保存的时候自动格式化
|
|
|
|
|
- // "editor.formatOnSave": true,
|
|
|
|
|
- // //开启自动修复
|
|
|
|
|
- // "editor.codeActionsOnSave": {
|
|
|
|
|
- // "source.fixAll": "explicit",
|
|
|
|
|
- // "source.fixAll.eslint": "explicit",
|
|
|
|
|
- // "source.fixAll.stylelint": "explicit"
|
|
|
|
|
- // },
|
|
|
|
|
|
|
+
|
|
|
// 配置stylelint检查的文件类型范围
|
|
// 配置stylelint检查的文件类型范围
|
|
|
"stylelint.validate": ["css", "scss", "vue", "html"], // 与package.json的scripts对应
|
|
"stylelint.validate": ["css", "scss", "vue", "html"], // 与package.json的scripts对应
|
|
|
"stylelint.enable": true,
|
|
"stylelint.enable": true,
|
|
@@ -62,16 +55,27 @@
|
|
|
"package.json": "pnpm-lock.yaml,pnpm-workspace.yaml,LICENSE,.gitattributes,.gitignore,.gitpod.yml,CNAME,.npmrc,.browserslistrc",
|
|
"package.json": "pnpm-lock.yaml,pnpm-workspace.yaml,LICENSE,.gitattributes,.gitignore,.gitpod.yml,CNAME,.npmrc,.browserslistrc",
|
|
|
".oxlintrc.json": "tsconfig.json,.commitlintrc.*,.prettier*,.editorconfig,.commitlint.cjs,.eslint*"
|
|
".oxlintrc.json": "tsconfig.json,.commitlintrc.*,.prettier*,.editorconfig,.commitlint.cjs,.eslint*"
|
|
|
},
|
|
},
|
|
|
- // Disable the default formatter, use eslint instead
|
|
|
|
|
- "prettier.enable": false,
|
|
|
|
|
- "editor.formatOnSave": false,
|
|
|
|
|
|
|
|
|
|
- // Auto fix
|
|
|
|
|
|
|
+ // 保存的时候自动格式化
|
|
|
|
|
+ "prettier.enable": true,
|
|
|
|
|
+ "editor.formatOnSave": true,
|
|
|
|
|
+ // 开启自动修复
|
|
|
"editor.codeActionsOnSave": {
|
|
"editor.codeActionsOnSave": {
|
|
|
|
|
+ "source.fixAll": "explicit",
|
|
|
"source.fixAll.eslint": "explicit",
|
|
"source.fixAll.eslint": "explicit",
|
|
|
- "source.organizeImports": "never"
|
|
|
|
|
|
|
+ "source.fixAll.stylelint": "explicit"
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
|
|
+ // Disable the default formatter, use eslint instead
|
|
|
|
|
+ // "prettier.enable": false,
|
|
|
|
|
+ // "editor.formatOnSave": false,
|
|
|
|
|
+
|
|
|
|
|
+ // Auto fix
|
|
|
|
|
+ // "editor.codeActionsOnSave": {
|
|
|
|
|
+ // "source.fixAll.eslint": "explicit",
|
|
|
|
|
+ // "source.organizeImports": "never"
|
|
|
|
|
+ // },
|
|
|
|
|
+
|
|
|
// Silent the stylistic rules in you IDE, but still auto fix them
|
|
// Silent the stylistic rules in you IDE, but still auto fix them
|
|
|
"eslint.rules.customizations": [
|
|
"eslint.rules.customizations": [
|
|
|
{ "rule": "style/*", "severity": "off", "fixable": true },
|
|
{ "rule": "style/*", "severity": "off", "fixable": true },
|
|
@@ -88,27 +92,27 @@
|
|
|
|
|
|
|
|
// Enable eslint for all supported languages
|
|
// Enable eslint for all supported languages
|
|
|
"eslint.validate": [
|
|
"eslint.validate": [
|
|
|
- "javascript",
|
|
|
|
|
- "javascriptreact",
|
|
|
|
|
- "typescript",
|
|
|
|
|
- "typescriptreact",
|
|
|
|
|
- "vue",
|
|
|
|
|
- "html",
|
|
|
|
|
- "markdown",
|
|
|
|
|
- "json",
|
|
|
|
|
- "json5",
|
|
|
|
|
- "jsonc",
|
|
|
|
|
- "yaml",
|
|
|
|
|
- "toml",
|
|
|
|
|
- "xml",
|
|
|
|
|
- "gql",
|
|
|
|
|
- "graphql",
|
|
|
|
|
- "astro",
|
|
|
|
|
- "svelte",
|
|
|
|
|
- "css",
|
|
|
|
|
- "less",
|
|
|
|
|
- "scss",
|
|
|
|
|
- "pcss",
|
|
|
|
|
- "postcss"
|
|
|
|
|
|
|
+ // "javascript",
|
|
|
|
|
+ // "javascriptreact",
|
|
|
|
|
+ // "typescript",
|
|
|
|
|
+ // "typescriptreact",
|
|
|
|
|
+ "vue"
|
|
|
|
|
+ // "html",
|
|
|
|
|
+ // "markdown",
|
|
|
|
|
+ // "json",
|
|
|
|
|
+ // "json5",
|
|
|
|
|
+ // "jsonc",
|
|
|
|
|
+ // "yaml",
|
|
|
|
|
+ // "toml",
|
|
|
|
|
+ // "xml",
|
|
|
|
|
+ // "gql",
|
|
|
|
|
+ // "graphql",
|
|
|
|
|
+ // "astro",
|
|
|
|
|
+ // "svelte",
|
|
|
|
|
+ // "css",
|
|
|
|
|
+ // "less",
|
|
|
|
|
+ // "scss",
|
|
|
|
|
+ // "pcss",
|
|
|
|
|
+ // "postcss"
|
|
|
]
|
|
]
|
|
|
}
|
|
}
|