Javascript - Debugger

About

Debugger in Javascript

The debugger needs to be able to access the source map file in order to stop to breakpoint

List

Browser debugger

In the debugger window, you can set breakpoints in the JavaScript code.

Debugger keyword

If you put the debugger keyword in a script and that you open the devtool, browser debugger will show up.

  • On chrome, tip F12 to open devtool
  • Then tip F5 to refresh the page, the debugger should kickoff.
function toDebug(){
   let i = 1;
   debugger;
}
toDebug();
  • the devtool should stop at the line where the debugger word below is.

Remotely

Node


Powered by ComboStrap