Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to debug javascript on phonegap/android 2.2

I'm writing a mobile marketing app, which is supposed to work on both iOS and android 2.2. The app is working just fine on iOS, but several things aren't working on android. It seems like some javascript responsible for handling button press events, with jQuery, is the culprit, however, to find the location of the error, I'm looking at the old-school equivalent of printline. Does anyone know of anything more convenient?

like image 984
ecarew Avatar asked Mar 19 '12 13:03

ecarew


1 Answers

Don't dis the console.log, I've definitely found it to be useful with PhoneGap apps.

This page http://debug.phonegap.com/ gives you a rough equivalent of FireBug or Chrome's Developer Tools. Follow the instructions to add the JS include to your page and run your app. You should then be able to use the console.

like image 69
codemonkey Avatar answered Sep 27 '22 01:09

codemonkey