我尝试使用 Ionic build android --prod 构建项目,但始终出现以下错误:
<events-list>
组件在EventslistModule中声明:
declarations: [
EventsListComponent,
NewestEventsComponent
],
imports: [IonicModule, LoaderModule],
exports: [
EventsListComponent,
NewestEventsComponent,
],
schemas: [CUSTOM_ELEMENTS_SCHEMA, NO_ERRORS_SCHEMA]
})
export class EventsListModule {}
这是events-list.ts中的属性:
@Input() set eventChange(filteredEvents){
this.filteredEvents = filteredEvents;
if(this.initial == true){
this.loadData();
}
};
@Input() created:boolean = false;
@Input() search:boolean = false;
@Input() id:string;
@Input() answered:boolean = false;
@Input() fromCalender:boolean = true;
@Input() status:number = 4;
@Input() showMessages = true;
Ionic:
Ionic CLI : 5.4.4 (/usr/local/lib/node_modules/ionic)
Ionic Framework : ionic-angular 3.9.9
@ionic/app-scripts : 3.2.4
Cordova:
Cordova CLI : 8.1.2 (cordova-lib@8.1.1)
Cordova Platforms : android 8.1.0, browser 5.0.3, ios 5.0.1
Cordova Plugins : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 1.2.1, (and 30 other plugins)
Utility:
cordova-res : not installed
native-run : 0.2.8 (update available: 0.3.0)
System:
Android SDK Tools : 26.1.1 (/Users/leonardoprivat/Library/Android/sdk)
ios-sim : 8.0.2
NodeJS : v10.16.3 (/usr/local/bin/node)
npm : 6.9.0
OS : macOS Mojave
Xcode : Xcode 11.0 Build version 11A420a
当我在没有-prod 的情况下构建项目时,它会正常工作。
任何想法我如何解决这个问题?