settings.json 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. {
  2. // 指定行尾序列为\n(LF)或者\r\n(CRLF)或者auto
  3. // "files.eol": "\n",
  4. // 在保存时格式化
  5. "editor.formatOnSave": true,
  6. "editor.formatOnSaveMode": "file",
  7. "eslint.codeActionsOnSave.mode": "problems",
  8. "eslint.debug": false,
  9. // 保存时进行一些操作
  10. "editor.codeActionsOnSave": {
  11. "source.fixAll.eslint": "explicit",
  12. "source.organizeImports": "explicit"
  13. // 在保存时运行eslint
  14. // "source.fixAll.eslint": true,
  15. // "source.organizeImports": true // 保存时整理 import ,去掉没用的导包,会删掉declare global {import utils from 'billd-utils';},因此先不用
  16. },
  17. // "eslint.autoFixOnSave": true, // 废弃,使用editor.codeActionsOnSave替代
  18. // Path Autocomplete,这个插件能够支持路径补全,默认vsc默认的路径提示可能不会提示一些css或者jpg等资源,用这个插件可以完善vscode的路径提示
  19. "path-autocomplete.pathMappings": {
  20. "@": "${folder}/src",
  21. "script": ["${folder}/src/script"]
  22. },
  23. // 别名路径跳转,这个插件可以完善vscode的跳转
  24. "alias-skip.allowedsuffix": [
  25. "css",
  26. "less",
  27. "sass",
  28. "scss",
  29. "jpg",
  30. "jpeg",
  31. "png",
  32. "webp",
  33. "gif",
  34. "svg",
  35. "js",
  36. "jsx",
  37. "ts",
  38. "tsx",
  39. "vue"
  40. ],
  41. // "typescript.tsdk": "node_modules/typescript/lib",
  42. "vue.codeActions.savingTimeLimit": 2000
  43. }