由于 Typescript 引入了对动态运行时错误的严格空检查,如果启用它会很棒。我找不到有关如何启用它的任何文档或指南。
如何在 VSCode 中启用严格的 null 检查?
最佳答案
couldn't find any docs or guidelines on how to enable it.
只需使用 tsconfig.json
的 compilerOptions
。例如。
{
"compilerOptions": {"strictNullChecks":true}
}
关于typescript - 如何为 vscode 启用严格的空检查,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40097895/