Deciphering Error Messages and Performance Leaks

Of course, no good language is complete without a means to detect and diagnose problems in your code. JavaScript provides rich error messages that are incredibly powerful and intuitive, but there are a few caveats and tips as you tiptoe through bug-ridden code.

As you probably know, finding a problem in your own code (a "bug") is one of the most frustrating events to occur to a developer. We pride ourselves on our code's ability to do its task, but sometimes we don't account for edge and corner cases. Additionally, error messages give us important information as we're in the process of coding by giving us important diagnostic information. Luckily, there are tools that can help us understand ...

Get Hands-on JavaScript for Python Developers now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.