How to detect if I am in browser (local development) in Ionic 2
Here you go., you can use the following function in replacement of your click function. onClickOfButton(){ // Check If Cordova/Mobile if (this.platform.is(‘cordova’)) { window.location.href = url; }else{ window.open(url,’_blank’); } } This can be helpful 🙂