MorJS tsconfig.json 配置
2024-01-24 09:34 更新
基础
tsconfig.base.json
配置{
"compilerOptions": {
"declaration": true,
"target": "ES2019",
"importHelpers": true,
"moduleResolution": "Node",
"sourceMap": true,
"noImplicitOverride": true,
"noUnusedLocals": true,
"esModuleInterop": true,
"lib": ["ES6", "ESNext", "DOM"]
}
}
运行时 tsconfig.json
配置
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"target": "ES5",
"rootDir": "./src",
"outDir": "./lib",
"module": "CommonJS",
"skipLibCheck": true,
"typeRoots": ["./node_modules/@types/"]
},
"include": ["./src"]
}
编译时 tsconfig.json 配置
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./lib",
"module": "CommonJS",
"typeRoots": ["./node_modules/@types/"]
},
"include": ["src"]
}
以上内容是否对您有帮助:
更多建议: