Questions tagged [javascript-debugger]

JavaScript debugger are tools that let you debug your JavaScript code by pausing the execution at any time, step through the code and see what each variable available looks like at that moment.

JavaScript debuggers allow step debugging of JavaScript code. Using them you can set breakpoints within the code. When a line of code is executed, which has a breakpoint set for it, the execution stops at that line and allows to execute the code step by step.

While stepping through the code the debugger displays all variables available within the current stack frame and typically also allows you to set some watch expressions.

As one of the main use cases for JavaScript are web browsers, different browsers have integrated tools to debug JavaScript. These tools are:

Furthermore IDE's like NetBeans or Eclipse also include debuggers for JavaScript.

See also

370 questions
0
votes
1 answer

Angular directives and the debugger

If I create an Angular directive: App.directive('modalWindow', function(){ return { restrict: 'EAC', link: function(scope, element) { elem.draggable(); } } }); and then reference it in markup:
Tim
  • 8,669
  • 31
  • 105
  • 183
0
votes
1 answer

Visual Studio 2012 javascript debugger stopped working

Visual Studio 2012 stopped debugging javascript files. Javascript debugging was working fine few days ago but all of a sudden it stopped working. I tried using script debugging in IE but I am not feeling comfortable with that. Anyone has a proven…
Vim
  • 559
  • 5
  • 16
0
votes
2 answers

Why is setting 'onClick' as event handler not recognized as syntax error?

My JavaScript code is: var headline = document.getElementById("mainHeading"); headline.onClick = function() { headline.innerHTML = "You clicked the headline."; }; But nothing happens when I click the headline. It just works when I use onclick…
Tuan van Duong
  • 185
  • 4
  • 14
0
votes
1 answer

Can I define how a browser displays an object?

I have a LinkedList object I created. In the debugger (for javascript/typescript) I want it to display as an array to make it easy to go view any element. Is there a way to do this in IE, Chrome, Firefox, or Opera?
David Thielen
  • 28,723
  • 34
  • 119
  • 193
0
votes
2 answers

MeteorJS debugger

Is there any way to set breakpoints and step through meteor server code? I'm not a fan of sticking a bunch of logging etc into the server code. I'd much prefer to use breakpoints. My IDE of choice is IntelliJ, I'd really like to do it in there if…
Ben
  • 16,124
  • 22
  • 77
  • 122
0
votes
1 answer

Debugger doesn't stop at breakpoints inside JQuery event handler functions (Chrome)

I noticed that breakpoints inside JQuery event handler functions are not triggered. If I put an alert or a debugger; it works fine. I cannot understand if this is a Chrome known issue or if this could be related to my specific configuration. I work…
kiks73
  • 3,718
  • 3
  • 25
  • 52
0
votes
3 answers

Push command in Javascript won't create the correct multidimensional array

I'm attempting to generate 10 random numbers 3 times and capture the hi, the lo, and last in every 10 number batch. I create an array of the hi/lo/last that gets pushed into another array so I can keep track of the numbers. Unfortunately the push…
0
votes
2 answers

How can I get IE 11 to show my .ts files?

I got IS 11 installed today (F12 in it rocks!) and at first it was displaying my .ts files in the debugger. But now it's displaying the .js files. Is there something I need to set? I use WebStorm to build my .ts files and it creates the map file. I…
David Thielen
  • 28,723
  • 34
  • 119
  • 193
0
votes
0 answers

Prevent all "debugger" calls from pausing javascript

I don't like debugger. It's a risky piece of code to be adding into an application. If this is accidentally left in the application prior to a live deployment, then the script will pause when developer tools are open. Is there a cross-browser way of…
Curtis
  • 101,612
  • 66
  • 270
  • 352
0
votes
1 answer

what is eval/seq/number.js in jquery or javascript

I really dont understand the need of the eval/seq/number.js and its effect on the web page. When i am dynamically loading the js files i found the pages to be in /eval/seq/some.js directory .Only issue iam facing is unable debug the code as the…
srinivas m
  • 19
  • 8
0
votes
4 answers

What's the best way to debug Javascript/AngularJS?

I just started learning Javascript and AngularJS and have a decent Java and C++ background. Today I wasted an entire day debugging a trivial error that boiled down to a missing comma in a JSON file: "name": "Melbourne", "snippet":…
noone__
  • 69
  • 1
  • 6
0
votes
1 answer

debugging dojo widget events - setTimeout vs the callstack

Often, I'll add an event handler to a dojo widget. For example, a handler for the change event. Then, something in my code will trigger the change event - but I don't know what. So, normally you just set a breakpoint in your favorite debugger, and…
goat
  • 31,486
  • 7
  • 73
  • 96
0
votes
1 answer

Common function for calling debugger; in Javascript

How can I make a common function in my global.js to for calling debugger; in JS. I'll basically set a value whether to debug or not. I tried the following but it's not working. Any lead will be appreciated.