Appirater适配StoreKit 2及iOS 18等新版本iOS系统的问题求助
Appirater适配StoreKit 2及iOS 18等新版本iOS系统的问题求助
各位开发者朋友好,我最近在维护一款老应用时遇到了Appirater的适配问题,想请教下有没有过来人能给点思路:
我这款应用原本用Appirater来触发用户评分提示,Appirater是SKStoreReviewController推出前的老库了,根据六年前的文档说明,它会自动检测并使用SKStoreReviewController(如果系统支持),不过需要手动配置StoreKit。
现在我要更新的新版本应用不再使用旧版StoreKit,换成了StoreKit 2。测试时发现:
- 旧版本应用在iOS 16设备上运行正常,Appirater弹窗能正常弹出,点击评分按钮可以跳转到App Store的评论页面;
- 但新版本用了StoreKit 2后,不管是在模拟器还是真机上,Appirater的弹窗虽然能正常显示,但是点击评分按钮完全没反应——既不会唤起Apple的SKStoreReviewController内置评分界面,也不会跳转到App Store写评论。
目前我的Appirater配置如下:
- 在
Appirater.h里设置了static BOOL _debug = YES;,确保每次启动应用都会弹出评分提示; - 在
AppDelegate的applicationDidFinishLaunching:方法里的配置代码:
//APPIRATER //TO GET APPIRATER TO LAUNCH YOU CAN DO EITHER OF THE FOLLOWING //call [Appirater userDidSignificantEvent:YES]; //may take more than once //call [Appirater rateApp];//immediate //Set appid [Appirater setAppId:@"1XXXXXXXX1"]; //ADJUST THESE NUMBERS TO GET IT TO APPEAR MORE OR LESS OFTEN [Appirater setDaysUntilPrompt:7]; [Appirater setUsesUntilPrompt:5]; [Appirater setSignificantEventsUntilPrompt:-1]; [Appirater setTimeBeforeReminding:2]; //UNCOMMENT THIS TO SEE APPIRATER ON LAUNCH #if DEBUG // [Appirater setDebug:YES]; #else [Appirater setDebug:NO]; #endif [Appirater appLaunched:YES];
现在我在纠结两个方向:要么直接弃用Appirater改用原生SKStoreReviewController的逻辑,要么尝试修改Appirater让它适配StoreKit 2和最新iOS系统。想问问有没有朋友成功让Appirater在StoreKit 2环境和新版本iOS上正常工作的?或者有没有什么排查方向可以推荐?
内容来源于stack exchange
相关产品推荐
相关产品推荐

