I have a form in html ( Angular ) and according to an event I must execute a function that recovers the value of one input and prints it in another, I did it in jQuery without problems in this way:
$('#selector').on('change', function(){
var valor_obtenido = $('#selector option:selected').val();
$('#input_tipo_texto').val(valor_obtenido);
});
Now what I need is instead of using jQuery, I should do the same but with Angular 5 , how could I do this?
Here I have the HTML:
<label for="selector">Selector:</label>
<select name="selector" id="selector" #selector="ngModel" [(ngModel)]="formulario.selector" class="form-control" required>
<option *ngFor="let formularios of formulario" value="{{formularios.selector}}">{{formularios.nombre}}</option>
</select>
Thanks for the reply, greetings!