PhoneGap, Cordova: Cannot call method ‘alert’ of undefined at file..

Note to self.

Say you are using Cordova, and you think you can just add in any old navigator.notification.* (navigator.notification.confirm) method you want. 

Well, first, please remember to read the documentation. Perhaps installing the dependencys would be nice.

http://docs.phonegap.com/en/3.0.0/cordova_notification_notification.md.html#Notification

If notification looks undefined, thats because it is.

 

cordova plugin add https://git-wip-us.apache.org/repos/asf/cordova-plugin-dialogs.git

try: cordova plugin add https://git-wip-us.apache.org/repos/asf/cordova-plugin-dialogs.git

 

 

Leave a Reply

Your email address will not be published. Required fields are marked *