Using deeplinking to share via WhatsApp

Note : I’ll keep track with the updates so when I find a solution or when someone help me the next developers who will face the same problem will understand how to deal with it

I’m working on a project , the project almost done but I need one last thing
I need the users to be able to share some pages in my app but the only problem is that as you know in the deeplinks in the ionic docs doesn’t show how to share dynamic pages
my problem is that I need to share a page which grabs some data from the internet based on the id it gets from the navParams
to be more clear here is my navigation function :

  nextPage(id : string,name : string ,biz : string,image : string,rat : number){
      tid : id,
      tname : name,
      tbiz : biz,
      timage : image,
      ra : rat

as you can see the ( sti ) page is giving some data so how can I pass this data in the deep linking ?
of course the most important thing to me is the ( tid ) the other data I can reload them easily if needed
I saw this article put it wasn’t clear to me how to do what I need to do :

any ideas ?

Edit : After some search I found that I need to use ionicPage() , here is it’s docs :

However I’m still trying to understand how to use it

still don’t know how to do it !

I’m not going to be any help - but this crossed my mind first - Good luck!

Yeah, no on the previous post. Ionic does not use Angular’s router.

1 Like

so how can I implement this functionality ? :frowning:

I would be surprised to learn that it is currently possible.

actually I was able to create a custom link for the app successfully with deeplinks (like instagram://)
but the problem is that I couldn’t pass the parameters I don’t know why !

Are you using the segment parameter in your @IonicPage decorator as documented in the “Dynamic Links” section of the second doc link in your first post?

Hey, I think I can help on this one. I did a small write up about dynamic links with firebase and branch, and we can modify the end result a bit to add some extra parameters.

Dynamic Links, Firebase vs. Branch

So in the end, to direct people to specific content I used a variable called $deeplink_path which then routed people to specific content.

But in practice, you could add as many of these parameters as you want.

$deeplink_path , $messagId, $messageSender …

And then use the nav controller to push the correct path to the user.

this.nav.push( DeeplinkPath, { messageId: $messagId }) … something like this.