【发布时间】:2019-02-01 15:44:06
【问题描述】:
这是我的第一个 cordova 应用程序,我正在尝试使用 cordova.plugins.diagnostic 插件。我相信我已经正确安装了它。在设备准备就绪时,我可以提醒您
alert(cordova.plugins.diagnostic != null) // returns true
// Appears to do nothing, i get no alerts
cordova.plugins.diagnostic.isLocationEnabled(function(enabled){
alert(enabled)
}, function(){
alert("ERROR");
});
我认为我的错误在于我运行应用程序的方式。我通过
构建应用程序cordova build ios
然后我通过 xCode 9.4 将构建运行到本地 iPhone X
非常感谢任何关于我做错了什么的想法。
【问题讨论】:
标签: xcode cordova cordova-plugins