-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathtsconfig.json
More file actions
27 lines (27 loc) · 1.02 KB
/
Copy pathtsconfig.json
File metadata and controls
27 lines (27 loc) · 1.02 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
// https://www.typescriptlang.org/zh/tsconfig
{
"compilerOptions": {
"target": "ESNext", // 为发出的 JavaScript 设置 JavaScript 语言版本,并包括兼容的库声明
"useDefineForClassFields": true, // 发出符合 ECMAScript 标准的类字段
"module": "ESNext", // 指定生成的模块代码
"moduleResolution": "node", // 指定 TypeScript 如何从给定模块说明符中查找文件
"strict": true, // 启用所有严格类型检查选项
"sourceMap": true, // 为发出的 JavaScript 文件创建源映射文件
"resolveJsonModule": true,
"esModuleInterop": true,
"lib": ["ESNext", "DOM"],
"skipLibCheck": true,
"typeRoots": ["node_modules/@types", "@types"],
// 单元测试的支持
"types": ["vitest/globals"],
// 解决测试文件中的 '--isolatedModules'报错
"isolatedModules": false
},
"include": [
"global.d.ts",
"packages/**/*.ts",
"packages/**/*.d.ts",
"packages/**/*.vue",
"play/main.ts"
, "demo/layout/layoutDemo.vue.ts" ]
}