I found this answer on StackOverflow which seems to work but still requires modifying the source file.
alert("First."); debugger; // Trigger a breakpoint. alert("Second.");
Of course that’s somewhat dated - now you’d use console.log rather than alert for your debugging and have alert turned off in the browser.
Well no because the ide stops at that break point and than you can further step in and out of code line by line. I think there is also a way to do it without modifying the file but I’m have trouble figuring it out.
No one is disagreeing with that.
It is unnecessary to stop the code immediately before and after the breakpoint using antiquated alert debugging calls though.
Well you don’t actually need console.log calls either side of the break created by the debugger call either.
That call by itself should start the debugger and allow you to set the breakpoint - to the best of my knowledge of how it works - although it is browser dependent.
This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.