Can FirebaseAuth 5.0.x be used in an iOS app extension?

流过昼夜 提交于 2019-12-12 12:55:32

问题


FirebaseAuth uses [UIApplication sharedApplication] in FIRAuth.m. Since that API is not available to App Extensions, it appears that FirebaseAuth (and anything that depends on it, such as Firestore) can not be used in an App Extension.

Is there any way around this limitation?


回答1:


Update:

Firebase confirms that a fix is targeted for 5.2.x version. Track the Github issue for latest updates.


It seems as Firebase is not officially supporting extensions in iOS. I have got that info from this GitHub issue (see paulb777's answer). Maybe someone from Firebase can also confirm this here. I am very surprised that we can't use Firebase SDK when creating extensions such as a Today widget.

The only workaround I had was reverting back to an earlier version of Firebase via:

pod 'Firebase', '4.9.0'

This uses the 4.9.0 version of the Firebase SDK and doesn't create compiler errors.



来源:https://stackoverflow.com/questions/50592585/can-firebaseauth-5-0-x-be-used-in-an-ios-app-extension

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!