我一直在使用Dialogflow(以前是Api.AI)制作聊天机器人,但现在在集成项目到我用Xcode用Swift编写的应用程序。我使用终端 sudo gem install cocoapods并使用
在您提供的图像中清楚地显示出您已经打开了项目文件而不是工作区。
I've been making a chatbot using Dialogflow formerly Api.AI but now encountering error while integrating the project to my app written in Swift in Xcode. I'd installed cocoapods using terminal "sudo gem install cocoapods" and using this version of Dialogflow to create the podfile.
All gone well but now when I'm importing inside Xcode in my app's AppDelegate.swift file using import ApiAI or import AI Xcode is showing me error that No such module. Please refer to image.
And on GitHub this library which is written in Swift, showing that it has depreciated and asking me to refer to API.AI's Apple Client library which is in Obj-C and unfortunately I've no expertise in Obj-C.
解决方案After installing a pod using Cocoa Pods, you must from that point forward open the workspace rather that the project file. The icons will appear differently in your project like so:
In the image you provided is clearly showing that you have opened the project file not the workspace one.
更多推荐
即使我已经安装了Cocoapods并安装了Dialogflow的Pod文件,Xcode仍显示错误“没有这样的模块”
发布评论