Is there a way for me to view my timer's countdown as it starts? I have attempted to bind it to a variable, but all I see is [object Object]
:
setTime(time) {
if (this.settime >= 5 ) {
this.currentTime = time;
this.alerttime = this.settime;
this.notifiy.showInfo( 'Timer set for ' + this.settime + ' Minutes train is due in ' + time + ' Minutes' , '');
const val = this.settime * 60000;
const source = timer(val);
this.time = source;
console.log(this.time); // this prints out the observbale function Ive also tryed to bind it in the subscribe method but no joy.
const subscribe = source.subscribe(value => { this.alertTimer(); });
this.settime = '';
//cordova.plugins.backgroundMode.enable();
} else {
this.notifiy.showFailure('You cant set the timer below 5 minutes', '');
}
}
I'm struggling to pinpoint where I may be going astray.