What are the differences between the console.log extension in Chrome for desktop and for iOS? - google-chrome-devtools

I've written a Javascript app and used console.log with format strings to help debug. It works fine on Chrome on Mac desktop. On Chrome for iOS, it logs the format strings instead of the corresponding positional parameters.
What I tried was...
I hunted around the Chrome Developers website on the Formatting console.log messages page here: https://developer.chrome.com/docs/devtools/console/format-style/, and tried out the new YOu.com search engine, but couldn't find the docs that say that console.log works differently on iOS Chrome.
Do I need to re-write my console log messages into the style of "msg1" + "msg2" + ... ?

Related

Chrome DevTools - SQL query not executed

I try to execute an SQL query with Chrome DevTools for an Android app, but it's not possible, because enter button moves the cursor to the next line instead of executing a commend. It worked some time ago.
I reinstalled Chrome, removed all Chrome data and reinstalled, used Chromium browser, but still no result.
All the other functions of DevTools are working correctly, e.g. networking, database preview.
It's happening with different apps and devices.
Could anyone help?
This is a bug in new versions of Chrome. So far, the only workaround I found is to download an earlier version, 71, for example from here:
https://www.slimjet.com/chrome/google-chrome-old-version.php
You can look here for a detailed discussion:
https://github.com/facebook/stetho/issues/634

How can i troubleshoot web page on IPhone?

I have been working on a web site that i want to work on any device. It works great on all my devices except my work IPhone. Is there any kind of console or other trick I can use to troubleshoot why it is not working? Something like chrome and firefox ctrl+shift+j would be nice.
In Chrome Dev Tools you can emulate a multitude of devices with differing resolutions and other limitations: Sitepoint blog regarding emulation
you can attempt to use emulation using most any browser F12 or Inspect or the multitude of online ones (google it)
In chrome on PC hit f12 then Ctrl-shift-M

Samsung SSSP device browser debugging

Is there any way to get some sort of developer console for the browser on a Samsung SSSP device? I have both a 10" and 32" device, but I can't seem to find any way to "debug" the browser. I'd like to have something like Firebug or the Chrome developer console where I can inspect the various elements and figure out why things are looking the way they look and not formatting like I would expect them to.
Use weinre.
https://people.apache.org/~pmuellr/weinre/docs/latest/Home.html
Just include the script tag with a script and it will give you Chrome like console. You can run Javascript remotely on the device.

Open with Google Chrome app

Is it possible to make a Chrome app handle certain types of extensions?
For example, setting a Chrome app to be launched when you double click a .txt file, instead of launching the Chrome app first and browsing for the file.
Yes, on ChromeOS via file_handlers. On other operating systems, not yet.
The bug to track this work on Windows: https://crbug.com/130455
Linux: https://crbug.com/138665
I'm not sure if / where there is a mac bug but it is also planned.
This should help you : http://www.computerhope.com/issues/ch000128.htm
Especially the part at the end of it.
In the future - Google it, it was like the 2 result.

How to display console.log() output in PhoneGap app using Eclipse and HTC Desire HD?

I am developing PhoneGap webapp where I use some javascript, and sometimes I need to see console.log() output. I can easily see it when running in Chrome, it also works fine, when running this app in Android emulator - output of console.log() shows up in Eclipse LogCat window. But when I run this app on my HTC Desire HD, LogCat just shows some Android-specific output, but nothing coming from my webapp.
Anybody has idea how to display console.log() output from PhoneGap-app running on HTC Desire HD ?
Another workaround is to use console.log() jsconsole.com
See the PhoneGap mail list thread. Also, two stackoverflow threads here and here.
It seems that console.log is disabled on HTC devices running Android 2.2.
The best workaround I've found is to use weinre, which intercepts the console.log to show the output in its desktop browser console.
Update: PhoneGap 1.3.0 now supports console.log directly to LogCat from the HTC Evo without any workarounds. (The same program doesn't work with PhoneGap 1.1.0)
I've found that console.error gets higher priority than console.log , and appears in the adb logcat output for both emulator devices and real devices connected via USB.
Try this filter:
adb logcat PhoneGapLog:V *:S
It will only show console.log and phonegap specific output.