How can I implement Sign-In-With-Apple in a webview? - ios

I have implemented SIWA natively on iOS, however it is only offered on iOS 13+. Is there a way to do an iOS 12- fallback SIWA in a webview? I am having trouble finding any examples of this.

Sign in With Apple doesn't make the whole app incompatible with iOS 12 or lower (the same is for SwiftUI).
If you want to support Sign in With Apple on older versions of iOS (as well as the non-iOS platform) you can use Sign in with Apple JS framework.
Useful link: https://forums.developer.apple.com/thread/119198

Related

Where is pausesLocationUpdatesAutomatically defined for Swift 5?

I am writing an independent WatchOS App that uses CoreLocation. I want to ensure that location updates are never paused. Apple defines pausesLocationUpdatesAutomatically here, which is exactly what I was looking for. The only problem is that it is not available for WatchOS apparently. In an iOS app it is available. Once I realized this, I checked in CLLocationManager.h and it isn't there at all.
Then I found on a Microsoft site of all places (Xamarin) that it is unavailable for WatchOS apps, and is available for iOS apps.
How can I find info like this either from Apple's docs or in the header files...this is pretty confusing to me. It was not clear to me on the Apple website that this would be unavailable for a WatchOS app.
On the Apple page you linked to, look at the list of SDK's on the right - This property is only available on iOS after 6.0 and Mac Catalyst after 13.0.
If an SDK isn't listed (watchOS) then it isn't available on that platform.

MonoTouch (Xamarin.iOS) Facebook app switching support for iOS 5+

Is there a solution out there where I can happily use the Facebook 3.1+ SDK, with MonoTouch, for iOS 5+ users?
For users NOT using iOS 6 I want my game to switch to the Facebook iOS app for authentication as normal (if they have it), to avoid the barrier of them entering credentials.
The Facebook iOS SDK 3.1+ (Obj-C) allows this functionality, and it uses the native library if users have iOS 6.
Unfortunately I'm unable to find that functionality for MonoTouch, where my app can easily switch to the Facebook app and quickly authenticate the user, for non iOS 6 users.
I've narrowed down my MonoTouch Facebook options to the following, none of them ideal:
Limit my game to iOS 6, which would allow me to use the monotouch-bindings/facebook native library
Use the Xamarin.Social component, which requires login details (no app switching) and has poor UI
Use a (unsupported since 2011) MonoTouch Facebook 3.0 library, there's a couple out there
Convert the latest Facebook 3.2.1 SDK to MonoTouch, allowing for non-native app switching
The ideal solution would be option 4, which would give the user the app switching experience on any version on iOS. Unfortunately I wouldn't have a clue where to start with that and I haven't got the time to spend a week trying to convert/bind (?) it.
I'm really not keen on limiting the app to iOS 6 users, we want the app to reach as many people as possible.
Thanks in advance for any suggestions and ideas.
The Monotouch binding for the 3.2.1 facebook SDK is here.
Last I used it, it seemed to do everything you want.
There is a bug in Xamarin.iOS. Follow the progress on bug fix here: https://bugzilla.xamarin.com/show_bug.cgi?id=11041

iOS 6- : Facebook API

I'm developing a application that integrates with Facebook.
I read about integrating in ios 6, ok.
I downloaded the SDK and came with samples. I opened "Scrumptious", but it's for iOS 4.3!!
So, two questions:
There is any sample for iOS 6?
How can I develop my application that integrates with iOS 6 and others iOS, using Facebook SDK?
Thanks.
The latest version of the Facebook SDK works on all Apple-supported versions of iOS, i.e. 4.3+. If the device is using iOS 6 and you request your permissions in an appropriate fashion (ie, read first, write later) then it will use Apple's built-in Facebook support and the username/password the user has supplied elsewhere. However it'll also work on iOS 4 and 5 devices that don't have that support, supplying an appropriate in-app prompt or paging out momentarily to the Facebook app as appropriate.
Use of the Facebook SDK is therefore optional for accessing Facebook from iOS 6 but is likely a good idea because:
it also works under iOS 4 and 5; and
it supplies a lot of pre-built dialogues for common Facebook tasks.
So although Scrumptious will work on iOS 4.3 it is using the latest version of the SDK and will use the OS-level support if available.
One of the distinguishing features of the latest SDK versus the older ones is that FBSession now has a concept of the activeSession, i.e. it has singleton-like features that support a global modal session. That was added publicly in June last year. Scrumptious makes use of that feature, for example on lines 94, 130, 144, 152 and 159 of SCAppDelegate.m.
So to answer your question directly: you've quite probably already downloaded the correct SDK. You'd write exactly the same code to work with it under iOS 4, 5 or 6. The samples like Scrumptious are a good place to start.
If you want a great tutorial, you can start with Ray Wenderlich's site. They have a good beginning tutorial using the social framework. I actually bought his book iOS 6 by tutorial. It helped me make an app for a friend that integrates Facebook and twitter. It really helps you understand the social framework.
http://www.raywenderlich.com/
Are you trying to integrate with the ios6 SocialKit? You don't need to download an SDK for that, it's built into the OS. I would recommend using Share Kit if you want to support older ios versions.

Twitter integration that supports for IOS4 & IOS 5 and IOS6

I am trying to integrate twitter in my universal application which should run on devices with IOS4+. After googling i came to know that for the devices with IOS<4.0 we can use Sharekit and for the devices with IOS>5 we have to use the twitter framework. And that twitter framework should be added weakly (BuildPhases-> beside twitter framework make it optional).
Should i use both of them in my app? If so is there any samples that can be run on devices IOS 4+ devices with the help of either Sharekit or twitter framework. Checking the version of the device and proceeding with the relavant process(either sharekit or twitter framework) is possible? If possible can you help with the snippets or sample.
DETweetComposeViewController will give you a tweet composer on iOS 4 that looks like the native one in iOS 5/6. In iOS 5+ it will use the native twitter libraries instead. It's pretty straight forward to setup and use.

Facebook with iOS5 and iOS6

I'm about to release an app and it must support both iOS5 and iOS6. But with the new Facebook SDK 3.1 i'm not quite sure on how to integrate the Facebook functionality to work with both iOS versions.
What is the best approach to make both the login and wall posting actions to work in iOS5 and iOS6 version? Are there any best-practices already?
Many thanks in advance!
The latest Facebook SDK supports both iOS versions just as well. If you're on iOS6, it will use the built-in authentication, otherwise it'll automatically fallback to the old "fast-app-switching" or Safari model.
So if you implement the 3.1 SDK, you won't have to worry about how the user authenticates:
The main purpose of the upgrade is to bring compatibility with iOS
v6.0 and its native Facebook support. Using v3.1 of the SDK means that
your apps benefit greatly from that support when it is available, but
that they automatically fall back to use the previous app-switching or
web-based authentication flows on older versions of the operating
system.
More on implementing support for the built-in Facebook accounts on iOS 6: http://developers.facebook.com/docs/howtos/ios-6/

Resources