js-util

Home > rc-js-util > _Debug > configureBreakpoint

_Debug.configureBreakpoint() method

Most debuggers will ignore debugger statements in node_modules. Skirt around this by letting the consumer set their own callback for this.

Signature:

static configureBreakpoint(this: void, onBreakpoint: () => void): void;

Parameters

Parameter Type Description
this void  
onBreakpoint () => void called on debug assert etc, you should provide a function with a debugger statement.

Returns:

void

Example

// the braces are not optional
_Debug.configureBreakpoint(() => { debugger; })