Using Firebug and web development tools in other browsers, you can use commands such as
console.log(myVar);
observe variables, not more destructive alert. With consoles in most development tools, you can also run arbitrary Javascript snippets without changing the actual code, which can help a lot with Javascript debugging. Oh, and the break on error function also helps.
When you open Firebug, you see something like this. Go to the console tab and enable it:

>>>. - $('body').css('-moz-transform', 'rotate(10deg)'): D