The Console tab is a valuable debugging tool, so you can use it as a scratch pad for trying out code and evaluating variables as you diagnose your problem. Another hint: Are you fortunate enough to have a choice? Since it returns an empty array and we try to call toUpperCase on the first item which is undefined, since there are no items that gives you the error. Ad-free experience sponsored by:. The following tools works great for me: From the window that opens select the event you want to trace and then enter the expression to output.
Extremely easy to miss!
Script debugging in IE needs be enabled, which requires us to disable the first option out of the three. NET application, but that option sadly is not available so one of the other approaches is needed to get into Visual Studio's script debugger.
Related 3530. I can't seem to inspect variables or any handy stuff like that. Watchers You can add expressions to the Watches panel which displays the current value of the expression as you move through the code. Like 1.
We can see what properties this object has by simply typing its name into the window:. The Stacktrace tells you where the error occurred and the sequence of function calls that led there. Unfortunately the detailed error message can be quite cryptic, and probably not too much help in diagnosing the actual problem.
Provides Step-by-Step Guidance to Angular. To add an Event Tracepoint, click the button from the Breakpoints section.
Hot Network Questions. We've driven over 1. In a large project it can be difficult to track down why a property we expect to exist is undefined.