Copy & paste the code below to embed this comment.
ebednarz
Just a heads up: iOS apps like Bugaboo are handy, but many people do not know that they do not use Mobile Safari but the UIWebView control, and performance aside, some advanced features are not available at all.
As one simple example, in the latter the window.orientation property exists and is of type number but is always 0 (so you cannot feature-test if it actually works), and the orientationchange event doesn’t fire at all (consequently, the same is true in all third party browsers).
This doesn’t matter much for most simple websites, but for complicated web apps (where you’d need debugging most) it is quite useless.
Hi, great article, just to clear up one misconception, assertions are a very specific tool, if you read the wikipedia article about them there is a line that says : “Assertions should be used to document logically impossible situations and discover programming errors”, that means they are specifically not for checking whether arguments for a method exist or type checking.
The former is called defensive programming and makes it very hard to unit test and is also generally considered bad practice.
An example of when you might use assertions would be to check that the value of a radius property in degrees is between 0 and 360.
Before debugging the JS on-the-fly one should know that it has errors, if yes then where. We should make use of JSLint Validation or simply online JavaScript Lint @ JavaScriptLint.com or any other service like this. Analyze the place where you have error and then debug it on-the-fly. Liked throwing & catching mechanism of this article.
Copy & paste the code below to embed this comment.
Ian Ovenden
Hi, interesting article and very useful in todays climate. Regarding Dragonfly, has anyone got this to work on Opera Mini on iOS? When I try the “opera:debug” url I get the message that it’s an invalid address.
10 Reader Comments
Back to the ArticleGeorge Montana Harkin
You might also mention winre which can be used to debug other browsers remotely.
http://pmuellr.github.com/weinre/
George Dina
Firebug is another remote debugging tool.
I use it when debugging websites on older browsers
http://getfirebug.com/firebuglite
Tiffany B. Brown
George MH: I mentioned Weinre in the piece, though I didn’t cover it in depth. My understanding is that it works well with WebKit-based browsers.
George D: You’re right. I should have mentioned Firebug Lite. That was an oversight on my part, since I typically use Firebug within Firefox.
Saç kaynak
that error problems come to me everytime so difficult. you were explain very good, thanks a lot. i’ll try with your advices to…
ebednarz
Just a heads up: iOS apps like Bugaboo are handy, but many people do not know that they do not use Mobile Safari but the UIWebView control, and performance aside, some advanced features are not available at all.
As one simple example, in the latter the window.orientation property exists and is of type number but is always 0 (so you cannot feature-test if it actually works), and the orientationchange event doesn’t fire at all (consequently, the same is true in all third party browsers).
This doesn’t matter much for most simple websites, but for complicated web apps (where you’d need debugging most) it is quite useless.
Simon Kenyon Shepard
Hi, great article, just to clear up one misconception, assertions are a very specific tool, if you read the wikipedia article about them there is a line that says : “Assertions should be used to document logically impossible situations and discover programming errors”, that means they are specifically not for checking whether arguments for a method exist or type checking.
The former is called defensive programming and makes it very hard to unit test and is also generally considered bad practice.
An example of when you might use assertions would be to check that the value of a radius property in degrees is between 0 and 360.
fparent
“You could also use document.getElementById(‘result’), but document.querySelector() is more efficient”
Just curious as to why using querySelector is more efficient. Always thought getElementById was faster and supported everywhere.
ipraxa
Before debugging the JS on-the-fly one should know that it has errors, if yes then where. We should make use of JSLint Validation or simply online JavaScript Lint @ JavaScriptLint.com or any other service like this. Analyze the place where you have error and then debug it on-the-fly. Liked throwing & catching mechanism of this article.
Ian Ovenden
Hi, interesting article and very useful in todays climate. Regarding Dragonfly, has anyone got this to work on Opera Mini on iOS? When I try the “opera:debug” url I get the message that it’s an invalid address.
Ian Ovenden
Typical – after finding nothing for ages, I finally post and then discover that Opera Mini doesn’t yet support remote debugging.