JavaScript Errors and the Firefox Console

This post is more than 2 years old.

This may fall into the category of "so obvious I'm the only one who didn't get it", but I just had to share it. I'm preparing a blog post where I've got an intentional error in my JavaScript code. I noticed that it wasn't showing up in the Firefox console though. I added a console.log message before the error - and it showed up - but my error never did.

Check out the screen shot below:

Notice that CSS warnings are showing up - which is cool - and "1" is my console.log message. But my JavaScript error isn't there. I clicked the console drop down to see what options were there:

Yep - logging of errors is enabled. So what the heck? Turns out I had to also check the options on the JavaScript tab:

Ugh. I can't imagine why Errors would be turned off, but maybe it's a sensible default for some reason. That complaint aside - I have to say I really like the look of the console.

Raymond Camden's Picture

About Raymond Camden

Raymond is a developer advocate for HERE Technologies. He focuses on JavaScript, serverless and enterprise cat demos. If you like this article, please consider visiting my Amazon Wishlist or donating via PayPal to show your support. You can even buy me a coffee!

Lafayette, LA