So yesterday, for the first time in years, I started coding a little Javascript, so I finally had a reason to install and play with FireBug. It's great. By far the most useful feature to me so far is the interactive javascript console. You can say document.getElementById("foo") and it'll give you a debug list of all the properties for that element. And you can execute any Javascript and it'll show you the results.
It really shows the value of interactive consoles. In fact, that was the second interactive console I'd made use of for the day for a language that doesn't usually have one. I finished creating a fairly tricky API for my tagging system, and I wanted to test it all. So I whipped up my own web-based interactive console for PHP where I could type in code and have it be evaluated and see the output. I was able to run down my entire API pretty quickly and both knock out some minor errors, and convince myself that the code was probably correct. With the console I wrote I was able to run through my tests much faster than I'd have been able to any other way.
A console is so important to me that I feel kind of naked when I'm working in a language that doesn't have one. In particular, I really miss it when I'm working with Perl, especially given its baroque syntax and all the CPAN you're inevitably testing out.
Feel free to post a comment below. Please see my comment policy.
Formatting Rules (No HTML):