首页 > 解决方案 > Swift 包依赖:“没有这样的模块......” - 为什么?

问题描述

目标:学习如何向 Swift 包添加导入。
作案手法:使用 Apple 提供的示例作为基础。添加另一个导入(即 Alamofire)
结果: Alamofire 确实导入;但它的模块“找不到”。

包装:

在此处输入图像描述

来源:

在此处输入图像描述

问: 为什么会这样?
我错过了什么?

标签: swift-package-managerswift-package

解决方案


Check the target DeckOfPlayingCards, select the General tab, check Framework, Libraries, and Embedded Contents, make sure Alamofire is on the list


推荐阅读