繁体   English   中英

错误 TS5023:未知的编译器选项“strictTemplates”

[英]error TS5023: Unknown compiler option 'strictTemplates'

编译 angular 应用程序 (v10) 失败并出现此错误。

An unhandled exception occurred: tsconfig.json:14:5 - error TS5023: Unknown compiler option 'strictTemplates'.

14     "strictTemplates": true,
       ~~~~~~~~~~~~~~~~~

strictTemplates是 angular 编译器的参数。

在您的 tsconfig.json 中:将参数移动到angularCompilerOptions

"angularCompilerOptions": {
  ...,
  "strictTemplates": true,
  ...
}

Angular >= 9 是必要的。

更多信息在这里: https://angular.io/guide/template-typecheck

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM