TypeScript will always compile even if there are ridiculous errors in your project. This lesson shows how to configure your .tsconfig with "noEmitOnError" so that no files are output if tsc reports an error.
tsconfig.json:
{ "compilerOptions": { "module": "commonjs", "target": "es5", "noImplicitAny": false, "sourceMap": false, "outDir": "./dist", "noEmitOnError": true }, "files": [ "main.ts" ] }
本文介绍如何通过配置 tsconfig.json 中的 noEmitOnError 选项来避免 TypeScript 在遇到错误时仍然输出文件。这对于确保代码质量至关重要。
2230

被折叠的 条评论
为什么被折叠?



