-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathtsconfig.json
40 lines (33 loc) · 1.12 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
// 该配置用于 src 和 test目录的ts
{
"compilerOptions": {
// ts-node does not support any module syntax other than commonjs
// 生成代码的模块风格是commonjs 、ES6 or es2015、amd、umd、ESNext等风格
"module": "es2015",
// tsc编译输出的代码的es版本
"target": "ES5", // 生成的代码是 ES3 ES5 ES6 or ES2015 ES2016 ES2017 ESNEXT
"sourceMap": false,
// "allowJs": true, // 不能和declaration一起使用
"noImplicitReturns": true,
"noImplicitAny": true,
"strictNullChecks": true,
"noFallthroughCasesInSwitch": true,
"allowUnreachableCode": false,
"allowUnusedLabels": false,
"allowSyntheticDefaultImports": true,
"esModuleInterop": true,
"lib": ["es6", "ES5", "dom", "scripthost"],
"declaration": true, // 产出 *.d.ts,不能和allowJs一起使用
"declarationDir": "./dist",
"baseUrl": ".",
"paths": {
}
},
"compileOnSave": false,
"include": [
"src/**/*.ts"
],
"exclude": [
"**/*Spec.ts"
]
}