Quantcast
Channel: Ionic Framework - Ionic Forum
Viewing all articles
Browse latest Browse all 49218

Ion-toggle 2-way databinding not showing correct state on load

$
0
0

@8bhsolutions wrote:

ion-toggle always shows false state on page load, then will toggle to the ngModel databinding value.
Where as if it checked property is bound, and the status is shown correctly on load.

HTML

Toggle slide after load no binding

Typescript

public ngModelState: boolean;
public checkedState: boolean;

constructor(public navCtrl: NavController) {
    this.ngModelState = true;
    this.checkedState = true;
}

How do I get the 2-way data binding to load the view correctly?

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 49218

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>