views:

196

answers:

2

I'm trying to debug a javascript-heavy webapp running on the Palm Pre browser. There are various useful debugging messages that the app will output to console.log(). This app was not built specifically for the Palm Pre but runs great on other Webkit-based browsers such as Safari.

How can I view the output of console.log from the Web application running in the Pre emulator? It appears that it's possible to view output for an app built for Pre specifically, but not output from the web browser itself.

A: 

You can write your own implementation of console.log() which outputs to a new window or div. Something like YUI Logger or log4javascript.

Annie
+1  A: 

Use palm-log --system-log-level=info to turn on info-level logging (used by console.log) and create a file called framework_config.json in your application directory with the following contents:

{
    "logLevel": 99
}
Adam Backstrom
awesome! thank you for this tip
thrusty