首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Expo react原生脸书登录在iOS独立应用上崩溃

Expo react原生脸书登录在iOS独立应用上崩溃
EN

Stack Overflow用户
提问于 2021-07-12 10:08:54
回答 1查看 218关注 0票数 0

Facebook login在iOS独立应用程序上崩溃,但在本地博览会上运行良好。我尝试了互联网上的很多东西,但似乎都不起作用。

我的世博会诊断。

代码语言:javascript
复制
  expo: ^42.0.0 => 42.0.1
  react: 16.13.1 => 16.13.1
  react-dom: 16.13.1 => 16.13.1
  react-native: 0.63.4 => 0.63.4
  react-native-web: ~0.13.12 => 0.13.18
  react-navigation: ^4.4.3 => 4.4.4
  Expo Workflow: bare

Facebook博览会

"expo-facebook":"~11.3.1“

下面是我得到的错误。

代码语言:javascript
复制
FBSDKLog: *** <activateApp, FBSDKAppEvents> is not called on the main thread. This can lead to errors.
    
Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[__NSPlaceholderDictionary initWithObjects:forKeys:count:]: attempt to insert nil object from objects[2]'

任何帮助都是非常感谢的。谢谢。

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2021-07-21 01:43:10

我通过在Info.plist文件中添加以下几行代码解决了这个问题。

代码语言:javascript
复制
<key>UIAppFonts</key>
    <array>
        <string>AntDesign.ttf</string>
        <string>Entypo.ttf</string>
        <string>EvilIcons.ttf</string>
        <string>Feather.ttf</string>
        <string>FontAwesome.ttf</string>
        <string>FontAwesome5_Brands.ttf</string>
        <string>FontAwesome5_Regular.ttf</string>
        <string>FontAwesome5_Solid.ttf</string>
        <string>Fontisto.ttf</string>
        <string>Foundation.ttf</string>
        <string>Ionicons.ttf</string>
        <string>MaterialCommunityIcons.ttf</string>
        <string>MaterialIcons.ttf</string>
        <string>Octicons.ttf</string>
        <string>Roboto_medium.ttf</string>
        <string>Roboto.ttf</string>
        <string>rubicon-icon-font.ttf</string>
        <string>SimpleLineIcons.ttf</string>
        <string>Zocial.ttf</string>
    </array>

    <key>NSUserTrackingUsageDescription</key>
    <string>This identifier will be used to deliver personalized ads to you.</string>
    <key>LSApplicationQueriesSchemes</key>
<array>
  <string>fbapi</string>
  <string>fbapi20130214</string>
  <string>fbapi20130410</string>
  <string>fbapi20130702</string>
  <string>fbapi20131010</string>
  <string>fbapi20131219</string>
  <string>fbapi20140410</string>
  <string>fbapi20140116</string>
  <string>fbapi20150313</string>
  <string>fbapi20150629</string>
  <string>fbapi20160328</string>
  <string>fbauth</string>
  <string>fb-messenger-share-api</string>
  <string>fbauth2</string>
  <string>fbshareextension</string>
</array>


    <key>CFBundleURLTypes</key>
<array>
  <dict>
  <key>CFBundleURLSchemes</key>
  <array>
    <string>your facebookscheme id</string>
  </array>
  </dict>
</array>
<key>FacebookAppID</key>
<string>your facebook id</string>
<key>FacebookDisplayName</key>
<string>Your facebook display name</string>
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/68341237

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档