I have the following:
<input [(ngModel)]="title"></input>
<div class="list">
<div *ngFor="let list of lists>
<div (click)="updateNGModel();"> {{list.Name}}</div>
</div>
</div>
What I am trying to do is that let say there are 5 lists. When one of them is clicked, I would like to show the clicked value in the input field.
How do I create the two way binding between the value of lists and the input field value?
I am new to the angular and any help would be much appreciated.
Thank you.