Friday, June 22, 2018

See what is in state when debugging in Visual Studio Code 1.17.1.

Press Ctrl and backtick together to get the pane with the PROBLEMS, OUTPUT, DEBUG CONSOLE, and TERMINAL tags. At DEBUG CONSOLE call functions, etc. Assuming this code:

var doubleUp = (doubleMe) => {
   return doubleMe + doubleMe;
};
debugger;

 
 

If you were stopped at the debugger line, you could type this in at the prompt at the far base of the DEBUG CONSOLE tab:

doubleUp(12)

 
 

...and get:

24

No comments:

Post a Comment