“没有这样的模块”在快速操场上导入豆荚时 [英] "no such module" when Importing pods in swift playground
问题描述
使用Xcode 7.2.1。
我正在按照本教程操作,以使吊舱在操场上工作。我已经将游乐场添加到工作区中,并且podfile链接到游乐场。
但是导入仍然不起作用-没有这样的模块
// Podfile
目标'太空飞船'做
结束
平台:ios,'9.0 '
use_frameworks!
link_with'spaceships','imports','test'
Using Xcode 7.2.1.
I am following this tutorial to get pods working in playground. i have added the playground into the workspace, and the podfile is linking to the playground.
But importing still does not work - "no such module"
https://littlebitesofcocoa.com/138-using-cocoapods-in-xcode-playgrounds
// import does not work
// Podfile
target 'spaceships' do
end
platform :ios, '9.0'
use_frameworks!
link_with 'spaceships', 'imports', 'test'
https://github.com/mingyeow/ImportToPlaygroundDoesNotWork
Not a direct answer to the issues you get from this tutorial, but there's a new tool to automatically generate Playgrounds with pods that I often use.
It's called ThisCouldBeUsButYouPlaying and the source is on GitHub.
Basically it extends the CocoaPods installer, which is then able to generate Playgrounds.
Install:
$ gem install cocoapods-playgrounds
Create a Playground with Alamofire:
$ pod playgrounds Alamofire
Create a Playground with multiple pods:
$ pod playgrounds RxSwift,RxCocoa
The new Playground will automatically open.
You will have to first build the project, to enable the pods, then the Playground will be available.
这篇关于“没有这样的模块”在快速操场上导入豆荚时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!