Ionic 3: Clicking a DeepLink

Its been a good while sense I got looking through deeplinking.

Something I’m missing about calling/clicking a deep link in an Ionic App. Hoping I’m going down the right path here.

A deep link is just a URL. I have one set up through Branch.io. I want to be able to click this link in an Ionic app. This is what I’m doing now.
var link = document.createElement(“a”);
link.href =“https://cool-app.app.link/niceapp”;
link.id = ‘app-link’;
link.click();
document.getElementById(‘app-link’).remove();

On a Samsung S7 (android 8) click the link. The script code above is called.
So a browser opens then takes the user to app store. So far so good. A chrome screen is open in the users app history with a blank chrome tab. Also sometimes this won’t work, it just a blank chrome screen. (The URL is correct in the browser).
Is there a better way?

Once I have the linked app installed. Then try the deep link again, I am prompted to open the app or open it in chrome.
Any way to not have it to do this either?