为了安全起见,我已经安装了吊舱并更新了吊舱,但我敢打赌“没有此类模块'DisplaySwitcher'”错误。我是新手,所以这可能是我是菜鸟,但能得到帮助。
import UIKit
import DisplaySwitcher
class ViewController: UIViewController {
override func viewDidLoad() {
super.viewDidLoad()
// Do any additional setup after loading the view, typically from a nib.
}
override func didReceiveMemoryWarning() {
super.didReceiveMemoryWarning()
// Dispose of any resources that can be recreated.
}
}
Image 1
image 2
最佳答案
我安装吊舱。它工作正常。我还导入了Xcode 9.2和Swift4。确保在pod文件中安装了正确的pod。
检查GitHub链接
https://github.com/khawar512/DisplaySwticher
吊舱安装的图像。
关于swift - 在我的xcode9项目中导入DisplaySwitcher-不起作用,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/48136379/