如何在我的Podfile中指定react-native-onesignal的版本?

问题描述 投票:0回答:1

我正在关注this guide如何使用React Native设置OneSignal。在说In your Podfile, add the notification service extension...的部分中,说将以下内容添加到我的Podfile中:

target 'OneSignalNotificationServiceExtension' do
  pod 'OneSignal', '>= 2.9.3', '< 3.0'
end

我认为这已经过时了,因为我的react-native-onesignal版本是3.7.2。我应该如何在Podfile中更改此行以适应此较新版本?

react-native cocoapods onesignal podfile react-native-onesignal
1个回答
0
投票

您尚未指定您认为合适的版本范围,但如果此Pod遵循共同的约定,即只有在主要版本发生更改时才发生重大更改,那么您将使用约束条件

target 'OneSignalNotificationServiceExtension' do
  pod 'OneSignal', '>= 3.7.2', '< 4.0'
end
© www.soinside.com 2019 - 2024. All rights reserved.