You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. {
  2. "compilerOptions": {
  3. "strictNullChecks": true,
  4. "strictFunctionTypes": false,
  5. "noUnusedLocals": false,
  6. "noUnusedParameters": false,
  7. "noImplicitReturns": false,
  8. "noFallthroughCasesInSwitch": false,
  9. "target": "esnext",
  10. "module": "esnext", //module:指定哪种版本的模块化
  11. "moduleResolution": "node",
  12. "strict": false, //所有严格模式的总开关
  13. "jsx": "preserve",
  14. "sourceMap": true, //sourceMap 简单说,Source map 就是一个信息文件,里面储存着位置信息。也就是说,转换后的代码的每一个位置,所对应的转换前的位置。有了它,出错的时候,除错工具将直接显示原始代码,而不是转换后的代码。这无疑给开发者带来了很大方便。
  15. "resolveJsonModule": false,
  16. "esModuleInterop": false,
  17. "skipLibCheck": true, //跳过库文件的类型检查
  18. "alwaysStrict": false, //用来设置编译后的文件是否使用严格模式,默认为false
  19. "removeComments": true, //是否移除注释
  20. "lib": ["esnext", "dom"], //用来指定项目中使用的库
  21. "baseUrl": ".",
  22. "paths": {
  23. "@/*": ["src/*"],
  24. "components/*": ["src/components/*"],
  25. "utils/*": ["src/utils/*"]
  26. },
  27. "noImplicitAny": false, // 是否在表达式和声明上有隐含的any类型时报错
  28. "noImplicitThis": true, // 不允许不明确类型的this,【默认为true】
  29. "types": ["element-plus/global", "node"], //指定全局组件类型
  30. "allowSyntheticDefaultImports": true
  31. },
  32. "include": [
  33. //指定 TypeScript 编译器编译的文件列表。
  34. "src/**/*.ts",
  35. "src/**/*.d.ts",
  36. "src/**/*.tsx",
  37. "src/**/*.vue",
  38. "src/api/system/commonApi.js"
  39. ],
  40. "angularCompilerOptions": {
  41. "strictInjectionParameters": true,
  42. "strictTemplates": true,
  43. "fullTemplateTypeCheck": true
  44. },
  45. "editor": {
  46. "suggestions": {
  47. "strings": false
  48. }
  49. },
  50. "exclude": [
  51. //取消在 HTML 文件中的 TypeScript 校验
  52. // "src/**/*.vue",
  53. "node_modules/**/*",
  54. "elment-plus/**/*"
  55. ]
  56. }