expo-module.config.json
了解 expo-module.config.json 中可用的不同配置选项。
Expo 模块在 expo-module.config.json 中进行配置。该文件目前能够配置自动链接和模块注册。以下是可用的属性:
🌐 Expo modules are configured in expo-module.config.json. This file currently is capable of configuring autolinking and module registration. The following properties are available:
platforms— 支持的平台数组。可接受的值有android、apple(或使用更细分的ios/macos/tvos)、web和devtools(参见 创建开发工具插件)。apple— 针对苹果平台的特定配置选项modules— 要放入生成的模块提供者文件的 Swift 原生模块类名称。appDelegateSubscribers— Swift 类的名称,这些类通过ExpoAppDelegate来接收 AppDelegate 生命周期事件。
android— 针对 Android 平台的特定配置选项modules— Kotlin 原生模块类的全名(包名 + 类名),用于放入生成的包提供者文件中。