angular5子組件值變動,父組件監聽改變回調

子組件javascript

import { Component, Input, Output,EventEmitter } from '@angular/core';
 @Input() crrunKm: any;
 @Output() getCrrunKmChange = new EventEmitter<any>();
 this.getCrrunKmChange.emit(newVaule);

 父組件java

<parent-compononet  (getSearchStatusChange)="myCallback($event)" #modelNo></parent-compononet>
相關文章
相關標籤/搜索