项目环境:用的cordova开发,微信登录插件使用 https://github.com/xu-li/cordova-plugin-wechat
当前ios版本:11.2.2
if([WXApi isWXAppInstalled])
{
NSLog(@"wechat is install");
}
else
{
NSLog(@"wechat is not install");
}
if([UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"weixin://"])
{
NSLog(@"wechat is install");
}
else
{
NSLog(@"wechat is not install");
}
使用这两个方法,无论手机有无安装微信,都打印已安装。
有没有大神知道应该怎么解决?感激不尽