What I am trying to achieve is when I trigger my method "onUpdateMeasure($event)"
to update my {{unit}}
automatically. With what I’ve done, partially works, it updates the {{unit}}
value but only if you click the select (the one with the placeholder " placeholder="My Goal"
". What I want to achieve is when I click the first select and trigger "onUpdateMeasure($event)"
to update {{unit}}
on the second ion-select automatically, not only when I click on it. If you guys have any idea I would really appreciate it
my HTML
<ion-select
[interfaceOptions]="customInterfaceOptions"
interface="action-sheet"
(ionChange)="onUpdateMeasure($event)"
<ion-select-option value="k">k</ion-select-option>
<ion-select-option value="l">l</ion-select-option>
</ion-select>
<ion-select
[interfaceOptions]="customInterfaceOptions"
interface="action-sheet"
placeholder="My Goal">
<ion-select-option value="l02">{{unit}} per week</ion-select-option>
<ion-select-option value="l1"> {{unit}} per week </ion-select-option>
</ion-select>
my TS
onUpdateMeasure(e) {
let selection = e.detail.value;
if (selectiont === "k") {
this.unit = "kg";
} else if (selectionWeight == "l") {
this.unit = "lbs";
}
}