Facebook整合IOS 11 [英] Facebook integration IOS 11

查看:110
本文介绍了Facebook整合IOS 11的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在尝试使用cocoapods(Xcode 9.0,IOS 11)将Facebook与IOS应用程序集成. 在安装了pod并用所有fb信息调整了info.plist之后,我陷入了导入FacebookCore的困境(它不能与FBSDKCoreKit,FacebookLoginKit,FBSDKLoginKit一起使用). Xcode发出没有这样的模块"警告. 更重要的是,如果我选择运行该项目(不导入任何内容),它将发出20多个警告,包括Bolts框架,FBSDKCoreKit,FacebookCore等. 有人知道如何处理吗?

谢谢

编辑-> 手动导入Facebook框架使其可以工作,因此问题可能出在cocoapods上. 关于豆荚出问题的任何想法吗?

解决方案

我使用以下Pod实现了iOS 10的Facebook登录流程:"FBSDKCoreKit","FBSDKLoginKit","FBSDKShareKit","FBSDKMessengerShareKit".

它确实可以工作,但是在iOS 11中,它正在打开一个Webview以便在iPad上登录. 在iPhone上可能效果更好. Facebook文档中有一小段说明,即iPad至少在iOS 10上已降低了功能.我还不确定iOS 11 ...

要登录快速文件,只需导入FBSDKCoreKit和FBSDKLoginKit. 您所指的"FacebookCore"的版本为0.2.0,所以我不想自己使用那个. 在终端中运行命令"pod search --simple FacebookCore",以检查自己.

我记得也曾尝试过,但是框架中存在许多问题,所以我停止尝试,只去了普通的Facebook吊舱,而不是这个"Facebook for Swift"吊舱.

尝试在没有Facebook登录名的情况下遵循Facebook登录流程,这可能对您来说很有效.

(我找到了您的信息,因为我一直在寻找以下内容) 社交帐户已从设置iOS 11中删除.第三方应用程序不再有权访问这些登录帐户." : https://www.theverge.com/2017/6/5/15743010/apple-ios-11-wwdc-2017-facebook-twitter-social-accounts-login

...所以我想再也不能进行顺畅的社交媒体登录了.

I've been trying to integrate Facebook with an IOS app using cocoapods (Xcode 9.0, IOS 11). After installing pods and adjusting the info.plist with all fb info, I got stuck on importing FacebookCore (it won't work with FBSDKCoreKit, FacebookLoginKit, FBSDKLoginKit also). Xcode issues the "No such module" warn. More than that, if I choose to run the project (without importing anything), it issues more than 20 warns, including Bolts framework, FBSDKCoreKit, FacebookCore etc.. Does anyone know how to handle this?

Thank you

EDIT --> Importing the Facebook frameworks manually made it work, so the problem might be with the cocoapods. Any ideas about what went wrong with the pods?

解决方案

I implemented the Facebook login flow for iOS 10 using the following pods: 'FBSDKCoreKit', 'FBSDKLoginKit', 'FBSDKShareKit', 'FBSDKMessengerShareKit'.

It does work, but in iOS 11, it's opening a webview to do login on an iPad. It might work better on an iPhone. There's a small note in the Facebook documentation, that iPads have reduced functionality, at least on iOS 10. I'm not sure about iOS 11 yet...

To do login in a swift file, you only need to import FBSDKCoreKit and FBSDKLoginKit. The "FacebookCore" you're referring to, is at version 0.2.0, so I wouldn't want to use that one myself. Run the command "pod search --simple FacebookCore" in a terminal, to check for yourself.

I remember also trying it, but there were many problems in the framework, so I stopped trying, and just went for the normal Facebook pods instead of this "Facebook for Swift" pod.

Try to follow the Facebook login process without that one, and it might just work for you.

edit: (I found your post because I was looking for the following) "Social accounts have been removed from Settings iOS 11. Third-party apps no longer have access to those signed-in accounts." : https://www.theverge.com/2017/6/5/15743010/apple-ios-11-wwdc-2017-facebook-twitter-social-accounts-login

...so no more smooth social media logins, I guess...

这篇关于Facebook整合IOS 11的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆