-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtsconfig.json
54 lines (54 loc) · 1.24 KB
/
tsconfig.json
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
{
"compilerOptions": {
// 目标代码 ts-> js(es5/6/7)
"target": "esnext",
// 目标代码需要使用的模块化方案
"module": "esnext",
// 严格模式的检查
"strict": true,
// 对jsx进行怎么样的处理
"jsx": "preserve",
// 辅助的导入功能
"importHelpers": true,
// 按照node的方式去解析模块
"moduleResolution": "node",
// 跳过一些库的类型检测
"skipLibCheck": true,
// esmodel 和 commonjs能不能一起使用
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
// 生成映射文件 map
"sourceMap": true,
// 文件路径在解析时,基本url
"baseUrl": ".",
// 指定具体要解析使用的类型
"types": [
"webpack-env"
],
// 路径解析 类似于webpack里的alias
"paths": {
"@/*": [
"src/*"
]
},
// 可以指定在项目中可以使用哪里库的类型
"lib": [
"esnext",
"dom",
"dom.iterable",
"scripthost"
]
},
// 哪些文件需要tsc解析的
"include": [
"src/**/*.ts",
"src/**/*.tsx",
"src/**/*.vue",
"tests/**/*.ts",
"tests/**/*.tsx"
],
// 那些不需要解析
"exclude": [
"node_modules"
]
}