I found some problems doing that with Ionic 4 and I solved this in two differents ways, depends of 4.x version.
view
<ion-item>
<ion-label> A </ion-label>
<ion-radio
(click)="changeA()"
[checked]=a
>
</ion-radio>
</ion-item>
<ion-item>
<ion-label> B </ion-label>
<ion-radio
(click)="changeB()"
[checked]=b
>
</ion-radio>
</ion-item>
<ion-button (click)="remove()">
<ion-label>
CLEAN
</ion-label>
</ion-button>
controller
a = false;
b = false;
changeA(){
this.a = !this.a
if(this.a && this.b)
this.b = false;
}
changeB(){
this.b = !this.b
if (this.b && this.a)
this.a = false;
}
remove(){
this.a = false;
this.b = false;
}
If you found some problems, move click from ion-radio
to ion-item
in each radio button. In an example with 4.11.x
. I had to do it but I don't know exactly why.
You can play with an example here.
I hope it help somebody.