Universal links on iOS 8? - ios

I am starting to get friendly with deep linking and have read about universal links in iOS 9.3 above. I want to open my app from an email through deep linking.
I am able to do it with deep linking using universal links but how do I do it for below versions. Please help.

You have to use a custom URI scheme. Obviously you also need to do OS version detection to make sure you are using the appropriate approach.
The recommendation to try Firebase Dynamic Links or Branch (full disclosure: I'm on the Branch team) is a good one; it will save you a lot of work and headache.

Related

Can you set up iOS Universal Links without a separate website?

Is it possible to set up iOS universal links without having a separate website?
For example, if you want a universal link that 1) opens your iOS app if the user has it installed on their device and 2) opens up the App store listing on any device without the app installed.
It seems that having a separate domain you control is the standard way to do it. The Apple documentation (here), and other guides like here and here, seem to make it pretty clear that you need to add the JSON code in the Apple App Site Association file to a separate website that you control.
But is it possible to set up universal links without that website?
Detail:
For an iOS mobile app developer, setting up a separate website, dealing with website hosting, etc. is distinct from building an iOS app, and an involved additional task to go through just for universal links. Many developers might have a site already or have experience building websites in addition to mobile apps, but it's still a different thing than building mobile apps.
So I'm surprised if Apple assumes app developers have a website ready to go for the purpose. I note there are non-Apple alternatives that do similar things that clearly don't require a website.
Edit: I am familiar with alternative linking systems, such as Firebase and Branch. I want to see how you can do it with Apple Universal Links.
So let's say you want to stick with Apple universal links. Is there a way to do it without setting up a website, dealing with hosts (and potential costs for that), etc?
If it is necessary, what would be the cheapest and easiest way to set up the bare minimum site for a mobile developer that would work for universal links?

How do I find an apps/websites Deep Link?

I have a cordova app which uses the AppAvailability Plugin (https://www.npmjs.com/package/cordova-plugin-appavailability) and I have to find out if a specific app is installed. Its easy on Android, since I just know the packagename, but on IOS I have to know the URI Scheme or the DeepLink (eg. myapp://).
But I just seems to not be able to find out how to get it. Example is the asos.com.au website and their app. The Package name is 'com.asos.app', so that part is solved.
But if you go on the website (or in my usecase, if you are forwarding to their website) it opens the app if is available. And if it is available I want to have my app know that it wont redirect to the website (this is actually pretty important).
So, on IOS I have to know this URI Scheme.
Any Ideas?
This sounds like asos.com has implemented deep linking, and indeed http://www.asos.com/apple-app-site-association is present and looks good. Find more documentation here: https://developer.apple.com/library/content/documentation/General/Conceptual/AppSearch/UniversalLinks.html

Difference between Universal linking and old URL scheme in iOS

Could you please tell me the main difference in coding when changing from old custom url scheme to universal binding(Deep linking in iOS) introduced by iOS from iOS 9 onwards?
I believe that deep linking is still possible using custom url scheme. Is that correct? Thanks in advance.
I have referred the following links,
https://blog.branch.io/ios-9-2-redirection-update-uri-scheme-and-universal-links/
https://blog.branch.io/ios-9.2-deep-linking-guide-transitioning-to-universal-links/
But I would like to get a simple answer. So I rely on stack overflow :)
Universal link: more suited for web that all pages are linking with the app, you bind a pattern on your app and a json on your page for ios to recognize, dont need know the pattern of the other app to open it, more secure
URL scheme: create a pattern and your web redirect to that url so iOS can recognize, it show error if the app is not install, need to know the app scheme to open (also need list in plist)
They can be use together
That would be incorrect: beginning with iOS 9.2, Apple discontinued support for opening apps via URI Scheme. Universal Links were introduced with iOS 9.0 and as of iOS 9.2 they have been the only way to open apps via links.
URI Schemes were easier to configure than Universal Links, as they required little more than a single entry in the project's .plist file and code to handle the link in the didFinishLaunchingWithOptions and openURL functions of the AppDelegate class.
Universal Links rely on a remote "AASA" file to map links to apps. Configuration involves creating and hosting the AASA file and adding the associated-domains entitlement to the app (you do not need to worry about the AASA file if you are using Branch).
Universal Linking requires that there be code to handle referring links in the didFinishLaunchingWithOptions and continueUserActivity functions of the AppDelegate class.
No, customer URL scheme's would be removed in the upcoming versions of iOS since it is not secure and has a lot of privacy issues i.e, App A can get to know whether you are using B, like Facebook can know whether you are using Tinder. So universal links is the right way to go now.

Will Appstore reviewers allow us to use dynamic library in iOS8?

I read many articles about dynamic library usage including this page "Can you build dynamic library...".
As apple document said, "Frameworks for iOS. iOS developers can now create dynamic frameworks. Frameworks are a collection of code and resources to encapsulate functionality that is valuable across multiple projects. Frameworks work perfectly with extensions, sharing logic that can be used by both the main application and the bundled extensions.", see full page from here.
Taking the security issue as consideration, I got the reject reason of dynamic library before iOS8, see details from "DarkDust's answer". But, how does it "just work" in iOS8? #appstore_reviewers?
Anyway, currently I'm writing a sample demo app and try to upload it to Appstore for review, the main feature is downloading a framework from internet to client and dlopen it. Hope that really "just works"!
Besides, the deployment target is iOS7.0, not sure it could works well in it.
I didn't get a so clear understand on differences between "dynamic library" and "framework", I think they are the same and in this thread I mean "Cocoa-touch framework" which could create in Xcode 6.
Some background: I'm trying to build an iOS app which does't contain extension feature, my cocoa-touch framework is for easy expand without uploading a new version as it comes from internet....
UPDATE
I published a demo project GMDemo here, will try to upload to Appstore.
UPDATE2
I failed to dlopen my dynamic framework with invalid code signing error after many tries in iOS device. Sorry, no good news here. (Almost forgot to update this question, sorry! BTW)
App Store Review Guidelines explicitly prohibit that in 2.4.5 Apps that download code in any way or form will be rejected https://developer.apple.com/app-store/review/guidelines/
UPDATE3 just use the same code signing!!!
I have test it in ad-hoc environment!
when my dynamic library use the code signing with the same code signing,It works,
otherwise,crush!!

Facebook iOS SDK & backwards compatibility

I'm trying to wrap my head around this and figure out what would be the best approach:
I want to take advantage of all the new features that iOS 6.0 introduced in terms of interacting with facebook - this includes the built-in social framework that allows fast facebook SSO and native post dialogs. This is done fairly easily using the new Facebook iOS SDK v3.1.1.
The problem is that I also want my applications to be available for any non-iOS 6.0 adopters. This made me face a very ugly situation in which I need to create an elaborate social wrapper that would have to be compiled differently (with different FB SDKs) and to run separate code in order to support earlier iOS versions. Because a lot of the Facebook SDK already includes fallbacks and handles a lot of old, deprecated calls to the feed and dialog APIs, I figured that there must be a better way, while taking this in account, to create such a social wrapper.
I guess what I'm asking for here is any clue as to where to proceed from here. If anyone has ever tackled this issue (even in earlier versions of the SDK) I would be glad to know.
Thanks in advance
Weak linking is definitely the way to go here.
The 3.1.1 SDK can handle running on either iOS 5 or iOS 6, all you need to do is weak link the relevant frameworks in your build settings, and change the deployment traget to 5.0 (leaving the base sdk as 6.0).
Of course, you still need to handle the case when the native post dialog isn't available (You can use FBNAtiveDialogs' canPresentShareDialogWithSession: method) and use the SDK dialog instead.

Resources