Javascript is the unsung hero of the last few years. Originally designed as a lightweight scripting language, it's taken the weight of building complex browser applications onto its shoulders. There are definitely occasional creaks under the strain though, and if you're hitting problems, the first place to look is Quirksmode.
It's essentially a collection of Peter-Paul Koch's notes from his own work using JS for web development, but the breadth and depth of the coverage is amazing. Whether you need to restyle file upload buttons, communicate between windows, detecting keystrokes or discover which events work in different browsers, you'll find the definitive answer in a clear, well-written page.
If you're a Javascript developer, bookmark Quirksmode and buy his book. If you're not, hire him if you need any JS work. I want to make sure he keeps saving me vast amounts of debugging!