leo*_*019 5 xcode notifications swift onesignal
我的OneSignal模块有问题。它没有给我提供这样的模块OneSignal,而是由可可豆荚安装了它并use_frameworks!放在我的豆荚文件中。我真的不知道我还需要配置什么才能使其正常工作
我在这里尝试了其他解决方案,例如:
荚文件
# Uncomment this line to define a global platform for your project
# platform :ios, '9.0'
target 'Jaee2' do
# Comment this line if you're not using Swift and don't want to use dynamic frameworks
use_frameworks!
# Pods for Jaee2
pod 'OneSignal', '>= 2.5.2', '< 3.0'
end
target 'OneSignalNotificationServiceExtension' do
use_frameworks!
pod 'OneSignal', '>= 2.5.2', '< 3.0'
end
Run Code Online (Sandbox Code Playgroud)
AppDelegate当您在那里时是否也看到同样的错误import OneSignal?如果不是,请确保在 pod 文件中pod 'OneSignal', '>= 2.5.2', '< 3.0'为目标添加了OneSignalNotificationServiceExtension. 所以你的 pod 文件应该是这样的:
target 'OneSignalNotificationServiceExtension' do
# Comment the next line if you're not using Swift and don't want to use dynamic frameworks
use_frameworks!
# Pods for OneSignalNotificationServiceExtension
pod 'OneSignal', '>= 2.5.2', '< 3.0'
end
target 'test' do
# Comment the next line if you're not using Swift and don't want to use dynamic frameworks
use_frameworks!
# Pods for test
pod 'OneSignal', '>= 2.5.2', '< 3.0'
end
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
1078 次 |
| 最近记录: |