How to set up app transfer for web browser for iOS 8

I am trying to set up switching applications for a web browser for my own application, but have no luck. I'm sure I just skipped a step. Here is what i did

  • Updated my bundleId with the Associated Domains parameter and created a new provisioning profile on the dev site
  • Xcode has added my domains to the list of related domains on the Features tab
  • Created a json.txt file with my bundleId id, including the command id
  • Highlighted json.txt file with key and certificate, which I use for https
  • Uploaded the apple-app-site association file to the root directory of the site

I already have a Native App-to-Native Application Handoff and a Native Application-to-Web Browser Handoff. What am I missing?

This is the only documentation I have worked with.

https://developer.apple.com/library/mac/documentation/UserExperience/Conceptual/Handoff/AdoptingHandoff/AdoptingHandoff.html#//apple_ref/doc/uid/TP40014338-CH2-SW10

+6
source share
2 answers

We had the same problem, and we spent a lot of time to solve this problem.

We managed to solve this problem by adding the activitycontinuation key to our JSON file.

In the end, this is what our json looks like:

 { "webcredentials": { "apps": ["TeamID.bundleIdentifier"] }, "activitycontinuation": { "apps": ["TeamID.bundleIdentifier"] } } 

Be sure to check your json always (try jsonlint.com for this), since invalid json can easily cause errors and problems.

+5
source

You also have a problem, with the bonus you also get Universal Links for working in iOS 9. I tried everything above and still could not work reliably.

It seems that it’s slower to choose your own option in the browser continuation option.

It also seems like slowly updating the cache-applex-app-site-association, so you can change it and not see any change for a while.

One quirk: Universal Links seems to return activity.webpageURL.host as "www.example.com", while a handover returns "example.com".

Update: it works MORE if you use Safari as a browser instead of Chrome. Chooses a handover much faster and more reliable.

0
source

Source: https://habr.com/ru/post/977545/


All Articles