Reputation: 529
I'm developing a WP8 application in Cordova.
I already finished the app in Android and iOS, but on WP8 the 'deviceready' event is firing twice? :(
Still executing twice
- Cordova version: 5.0.0
- jQuery: 2.1.x
document.body.onload = onLoad;
function onLoad() {
console.log('onload');
document.addEventListener('deviceready', ready, false);
}
function ready(){
console.log('ready'); //firing twice
}
The following cordova plugins are installed:
And at last the debug information: http://pastebin.com/8FgLnULJ
Hope you guys can help me because I can't figure it out.
If someone needs more information, just ask me :)
Thanks!
Upvotes: 1
Views: 524
Reputation: 16
If you change console.log to alert then you will see that deviceready fired once... Console plugin for windows phone just doing duplicate of messages, try remove the plugin and you will see one message "ready"...
Upvotes: 0