@M4rt1n wrote:
Hy Guys!
I have same problem described here:
this may be a workaround? (seems work fine in my app)
let eventEmitter= new EventEmitter(); eventEmitter.subscribe(res=>{ console.log("emitterResult", res) }); const modal = await this.modalCtrl.create({ component: MyComponent, componentProps: { clickFavorite: eventEmitter } }); await modal.present()
export class MyComponent { @Output() clickFavorite= new EventEmitter<any>(); favorite(evt){ this.clickFavorite.emit("OK"); } }
<ion-card color="primary" > <div class="ion-text-end" (click)="favorite($event)"> blabla </div> </ion-card>
Posts: 1
Participants: 1