Visual Studio Code includes a powerful debugger that supports breakpoints, call stacks, variable inspection, and interactive console evaluation. The debugger works with Node.js out of the box and can be extended to support other languages through debug adapters.
export const CONTEXT_BREAKPOINTS_EXIST = new RawContextKey<boolean>( 'breakpointsExist', false, { type: 'boolean', description: 'True when at least one breakpoint exists.' });export const CONTEXT_BREAKPOINT_SUPPORTS_CONDITION = new RawContextKey<boolean>( 'breakpointSupportsCondition', false, { type: 'boolean', description: 'True when the focused breakpoint supports conditions.' });
// Logpoint message (use curly braces for expressions)User {user.name} logged in at {new Date().toISOString()}// Output:// User john.doe logged in at 2026-03-06T10:30:00.000Z
export const CONTEXT_VARIABLES_FOCUSED = new RawContextKey<boolean>( 'variablesFocused', true, { type: 'boolean', description: 'True when the VARIABLES view is focused' });export const CONTEXT_VARIABLE_EVALUATE_NAME_PRESENT = new RawContextKey<boolean>( 'variableEvaluateNamePresent', false, { type: 'boolean', description: "True when the focused variable has an 'evaluateName' field set." });
Navigate through the execution stack to understand the flow of your program:
export const CONTEXT_CALLSTACK_FOCUSED = new RawContextKey<boolean>( 'callStackFocused', true, { type: 'boolean', description: 'True when the CALLSTACK view is focused' });export const CONTEXT_CALLSTACK_ITEM_TYPE = new RawContextKey<string>( 'callStackItemType', undefined, { type: 'string', description: "Represents the item type of the focused element in the CALL STACK view" });
Click on any stack frame to navigate to that point in the code and inspect variables at that scope.
export const CONTEXT_DEBUG_STATE = new RawContextKey<string>( 'debugState', 'inactive', { type: 'string', description: "State that the focused debug session is in. One of: 'inactive', 'initializing', 'stopped', or 'running'" });export const CONTEXT_IN_DEBUG_MODE = new RawContextKey<boolean>( 'inDebugMode', false, { type: 'boolean', description: 'True when debugging, false otherwise' });
// The debugger has several optimization contexts:export const CONTEXT_STEP_BACK_SUPPORTED = new RawContextKey<boolean>('stepBackSupported', false);export const CONTEXT_RESTART_FRAME_SUPPORTED = new RawContextKey<boolean>('restartFrameSupported', false);export const CONTEXT_JUMP_TO_CURSOR_SUPPORTED = new RawContextKey<boolean>('jumpToCursorSupported', false);