These are some of the methods I use for debugging javascript in Firefox, Safari, Google Chrome, and Internet Explorer. Note the length difference between IE and everything else. Making matters worse, sometimes the worst bugs are IE-specific - I'll devote an entire post to IE javascript debugging in the future. If you're working with javascript across browsers, here are the basics.
Firefox
I'll start off with my favorite. Firefox makes things easy. I love Firebug. This is always my go-to javascript debugging solution.
SafariSafari | Preferences | Advanced
Check "Show Develop menu in menu bar"
Develop | Show Error Console (Option+Command+C)
Safari has a nice built in javascript debugger in the error console.
Google ChromeDeveloper | JavaScript console (Ctrl+Shift+J)
As you would expect, being a Google product, Chrome provides a nice console for debugging javascript.
Oh, Internet Explorer. You have so much market share and you are so hard to work with. DebugBar is a 3rd party toolbar that gives developers a little bit of help with javascript errors during runtime. Dragging a target over elements behaves similar to Firebug's Inspect. DebugBar also provides a javascript console for executing commands from IE.
IETester is an easy way to run multiple versions of IE on the same machine. This isn't specific to javascript, but you'll want to be able to test your sites in IE6, IE7, IE8. IETester lets you launch them from a single place.
Microsoft Script Debugger pops up an alert when a javascript error occurs on the page, allowing you to see where the error came from (the built in javascript debugger displays inaccurate line numbers).
I hope this overview got you started. What are your techniques for debugging javascript? Let me know in the comments!