In my PWA I'm implementing back and forward navigation buttons for when the app is in standalone mode. To achieve this I am injecting the Location service in my component and then:
public onForward() {
this.location.forward();
}
public onBack() {
this.location.back();
}
What I'm trying to do now is disable the forward button when there is no forward navigation available, and similarly disable the back button when there is no backward navigation available (e.g. app just launched). Any idea how to achieve this? The Location API doesn't seem to cater for this requirement.