如何创建 iOS 应用插件?

How to create an iOS app add-on?

是否可以在 iOS 应用中创建一个 API 以让第 3 方开发人员创建应用内用户可下载的应用插件?

我在网上找不到关于这个主题的任何资源。

如果您的意图是让第 3 方开发人员编写将被下载和执行的代码,我认为这将违反应用商店指南。

下载代码的合法使用和非法使用之间存在灰色地带:

合法示例 1:像 Hopscotch 这样的 children 正在创建简单有趣的共享游戏。这些可以被视为用户生成的内容。

合法示例 2:由脚本驱动的游戏允许 run-time 下载补丁以修复脚本中的错误,甚至可以添加新关卡。我相信这样的用法在过去偶尔会被拒绝,但现在已被普遍接受。

guidelines 中的相关指南是(强调我的):

2.5.2 Apps should be self-contained in their bundles, and may not read or write data outside the designated container area, nor may they download, install, or execute code, including other iOS, watchOS, Mac OS X, or tvOS apps.

和all-encompassing:

We will reject apps for any content or behavior that we believe is over the line. What line, you ask? Well, as a Supreme Court Justice once said, "I'll know it when I see it". And we think that you will also know it when you cross it.

如果您的想法是在您的 app-store 应用程序中创建某种 app-store,那么我会立即放弃它,因为这将超出 Apple 的范围。

也就是说,您没有提供有关您的应用程序的太多细节,所以我可能对您打算去的地方做出了错误的假设。