I was wondering if the type of javascript errors can be grouped into different categories and if there was an easy way of debugging them. While working on a ASP.NET application, I generally see 2 different types of JS errors:
-
Ones that say ‘Error occurred in xx. Do you want to debug’?
-
Ones that show errors with a icon on the bottom left side of the browser (When you double click, the error shows up)
Is there a good debugger for all JS errors (especially the ones with type 1?)
EDIT-
If I use Visual Studio to debug JS, can I have it setup to automatically open the line that caused the error in VS when I am not in debug mode? (We have a large .NET solution and to get to the JS debugger, I have to start in debug mode (The script explorer does not show up if I simply attach the debugger later))
There certainly is: Firebug. It’s a plugin for Firefox and you simply cannot developer a website without it.
Edit for more info.
The ‘type 1’ error you are talking about occurs in IE only. And you can debug it using a copy of Visual Studio.
Not that you would want to however. Just get Firebug and you’ll wonder how you ever developed without it before.