Helping web developers with JavaScript errors

Errors are one of the more frustrating things you encounter while  programming. Those little messages in the console can ruin your entire afternoon, day, or week. When “undefined is not a function” appears yet again, it’s often time to get another coffee.

Even if you use the one true JavaScript exception handler, and have a lightning fast “copy and paste into $search_engine” reflex, the process of tracking down helpful information about an error can be annoying.

It doesn’t necessarily need to be that way! Some programming languages (hi Rust) take their error reporting to the next level by providing more information than just the fact that something went wrong.

We are not introducing JavaScript Clippy today. However, with the help of the MDN community, we are going to add links to documentation from error  messages that appear within the Firefox Developer Tools console.

This is to help you debug faster and learn more about JavaScript’s edge cases and lesser known functionality. Especially if you are new to JavaScript, we hope that you’ll appreciate this additional debugging help, or for those times when you’ve had too much coffee and you still can’t find the solution.

Documenting all the JavaScript, DOM, and other varieties of error messages that are thrown at you is a lot of work. We are focusing on the most commonly thrown errors for now. If you feel like helping here, get in touch with the MDN community and we promise you’ll learn a lot about JavaScript’s interesting quirks!

Try a recent Nightly build of Firefox to test this feature, or have a look at the MDN JavaScript error documentation directly.

View full post on Mozilla Hacks – the Web developer blog

VN:F [1.9.22_1171]
Rating: 0.0/10 (0 votes cast)
VN:F [1.9.22_1171]
Rating: 0 (from 0 votes)

Leave a Reply