I have two components as "new" and "history". history component is called inside "new" component as follows,
<div class="col-lg-12">
<app-leave-history [LeaveData]="ldata" [RoleData]="permission"></app-leave- history>
</div>
above is inside "new" component. i need to pass data to 'ldata' property from "new" component ts file. when i pass data to 'ldata' with API response, component doesn't get data. because before the API response, history component get loaded. should i call the API inside the history component or is there any way to call API from my "new" component and pass to 'ldata'?