美文网首页
An unhandled exception occurred:

An unhandled exception occurred:

作者: 晨曦Bai | 来源:发表于2020-05-27 10:28 被阅读0次

Error: Failed to compile entry-point @angular/material/card (es2015 as esm2015) due to compilation errors:

node_modules/@angular/material/core/common-behaviors/common-module.d.ts:36:22 - error NG6002: Appears in the NgModule.imports of MatCardModule, but could not be resolved to an NgModule class.

This likely means that the library (@angular/material/core) which declares MatCommonModule has not been processed correctly by ngcc, or is not compatible with Angular Ivy. Check if a newer version of the library is available, and update if so. Also consider checking with the library's authors to see if the library is expected to be compatible with Ivy.

解决办法:

tsconfig.json
"angularCompilerOptions": {
"enableIvy": false,
}

agularCompilerOptions 和 compilerOptions 是两个不同的项

相关文章

网友评论

      本文标题:An unhandled exception occurred:

      本文链接:https://www.haomeiwen.com/subject/xdsvahtx.html