【发布时间】:2020-12-12 22:52:18
【问题描述】:
为什么我会收到Uncaught ReferenceError: Cannot access 'NgxMatCalendar' before initialization?
我使用shared.module.ts,在其中使用与我的组件相关的导入和导出,并且我有我的app.module.ts,我在其中导入SharedModule。但是,我已经导入了接下来的两件事
import { NgxMatDatetimePickerModule, NgxMatTimepickerModule } from 'ngx-mat-datetime-picker';
在我的 NgModule 导入中:
NgxMatDatetimePickerModule,
NgxMatTimepickerModule,
但可能出了点问题,我不知道为什么。
错误说:
checkout-overview.component.ts:13 中的代码行是:
@Input() cartId: string;
edit-event-dialog.component.ts:24 中的代码行在其构造函数参数中:
@Inject(MAT_DIALOG_DATA) public data: any,
我不知道为什么会出错。谁能帮我解决这个问题?
【问题讨论】:
标签: angular typescript angular-ui-router ngx-bootstrap uncaught-reference-error