Search Support

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Learn More

Is there any way to debug Javascript on Firefox Preview?

  • 4 replies
  • 1 has this problem
  • 17 views
  • Last reply by Kevin

more options

I'm redesigning an existing website. I have some Javascript which runs behind the search facility to make AJAX calls which populate an autocomplete. This works on every modern browser I've tested it in, but for some reason I can't make it work in Firefox Preview on my Android device. It *does* work with the original Firefox on that device.

Is there any way to get a Javascript console with this as I would with my desktop Firefox? Or is there a version I can run on my desktop which works (or more importantly, doesn't) on my Linux desktop?

I'm redesigning an existing website. I have some Javascript which runs behind the search facility to make AJAX calls which populate an autocomplete. This works on every modern browser I've tested it in, but for some reason I can't make it work in Firefox Preview on my Android device. It *does* work with the original Firefox on that device. Is there any way to get a Javascript console with this as I would with my desktop Firefox? Or is there a version I can run on my desktop which works (or more importantly, doesn't) on my Linux desktop?

Chosen solution

Thanks Ballison,

Unfortunately logcat output doesn't seem to show any Javascript-related output (ie, like the console on the desktop), so trying to debug with console.log() doesn't give any info.

However, for some reason the function that wasn't working "is" now working. Evidently as I've been working on my Javascript I've inadvertently solved the problem. Thinking about it, it may have been one of the changes I had to make to get the site working on IE9.

Read this answer in context 👍 0

All Replies (4)

more options

Hi foxfire4,

Have you tried connecting your android device via USB and using Remote Debugging? This should enable you to use the debugger on your desktop with the browser on your device.

If you need any help getting this set up or if you have tried this and ran into issues, please let me know!

more options

Chosen Solution

Thanks Ballison,

Unfortunately logcat output doesn't seem to show any Javascript-related output (ie, like the console on the desktop), so trying to debug with console.log() doesn't give any info.

However, for some reason the function that wasn't working "is" now working. Evidently as I've been working on my Javascript I've inadvertently solved the problem. Thinking about it, it may have been one of the changes I had to make to get the site working on IE9.

more options

Hi foxfire4,

I'm sorry my solution didn't work for you, but I'm glad to hear you managed to resolve it!

more options

You can use a USB connection and desktop Firefox to inspect pages on Firefox for Android or Preview. It is not possible to see javascript errors on adb logcat as it is a global resource that could leak user websites visits to any app.

https://developer.mozilla.org/en-US/docs/Tools/about:debugging