我想查看所有聯繫人,但navigator.contacts未定義。navigator.contacts未定義
cordova plugin add cordova-plugin-contacts
cordova build android
$(document).ready(function(){
$(document).on('deviceready', function(){
alert('something');
}, false); //it doesn't even alert something;
console.log(navigator.contacts);
});
我把它拿出來的文件準備無論是。沒有結果:(
有人說這個問題可以通過刪除和添加平臺android並重新添加插件來解決,但它沒有! 我也把腳本標記放到最後,以便頁面加載然後運行腳本
感謝編輯:) – codepro