I added Cordova-plugin-local-notification on my project(https://github.com/katzer/cordova-plugin-local-notifications). and I added this code to the project
cordova.plugins.notification.local.schedule({
title: 'My first notification',
text: 'Thats pretty easy...',
foreground: true
});
but it shows an error:
cordova is not defined
at new MyApp
how can I fix this issue? pls help
Need to, declare cordova like this,
declare var cordova: any;