How can I concatenate two variables in HTML?


#1

Hi,

Any idea how to concatenate two variable into one value ?

<ion-input formControlName="iNom" type="text" value="{{userDetails.first_name}}{{userDetails.last_name}}" [(ngModel)]="userData.NomConducteur"></ion-input>

#2

Please read

https://angular.io/guide/template-syntax

If at all you want to do this (which I wouldnt), it will probably will look like

value="{{userDetails.first_name + ' ' + userDetails.last_name}}" 

Tom