Debugging JavaScript Code
Two JavaScript topics in just one day… that’s critical! I should worry that something’s going wrong in my life.
This time it’s something good about JavaScript: debugging it. I never used JavaScript debugging until now, because on the one hand I don’t write much JavaScript code and on the other hand I somehow managed to survive with my typical “alert error-searching method”, even if such things drive you crazy from time to time.
Well, today I tried out Mozilla’s JavaScript Debugger “Venkman” for Firefox and I was surprised. It’s a great tool, really useful. Just search for it in Firefox “Tools” -> “Add-ons”, or go to this page, where the current version can be downloaded (link might change over time, I don’t know…).
First steps with Venkman can be a bit difficult, even though I’m familiar with debugging techniques and I often use Java debuggers, I had problems making Venkman do what I want. I guess there are plenty of documentations and tutorials on the net, however, I just want to recommend one that I found and (at least partly) read: Svend Tofte’s “Learning Venkman” Tutorial. Thanks for this nice tutorial, it helped me to get useful results with Venkman within a short amount of time.
I recommend trying out a JavaScript debugger like Venkman to all people that (have to) deal with JavaScript code. It really can make one’s life easier… 🙂