Options
All
  • Public
  • Public/Protected
  • All
Menu

The inspector.Session is used for dispatching messages to the V8 inspector back-end and receiving message responses and notifications.

Hierarchy

Index

Constructors

constructor

  • Create a new instance of the inspector.Session class. The inspector session needs to be connected through session.connect() before the messages can be dispatched to the inspector backend.

    Returns Session

Properties

Static captureRejectionSymbol

captureRejectionSymbol: keyof symbol

Static captureRejections

captureRejections: boolean

Sets or gets the default captureRejection value for all emitters.

Static defaultMaxListeners

defaultMaxListeners: number

Static errorMonitor

errorMonitor: keyof symbol

This symbol shall be used to install a listener for only monitoring 'error' events. Listeners installed using this symbol are called before the regular 'error' listeners are called.

Installing a listener using this symbol does not change the behavior once an 'error' event is emitted, therefore the process will still crash if no regular 'error' listener is installed.

Methods

addListener

  • addListener(event: string, listener: function): this
  • addListener(event: "inspectorNotification", listener: function): this
  • addListener(event: "Runtime.executionContextCreated", listener: function): this
  • addListener(event: "Runtime.executionContextDestroyed", listener: function): this
  • addListener(event: "Runtime.executionContextsCleared", listener: function): this
  • addListener(event: "Runtime.exceptionThrown", listener: function): this
  • addListener(event: "Runtime.exceptionRevoked", listener: function): this
  • addListener(event: "Runtime.consoleAPICalled", listener: function): this
  • addListener(event: "Runtime.inspectRequested", listener: function): this
  • addListener(event: "Debugger.scriptParsed", listener: function): this
  • addListener(event: "Debugger.scriptFailedToParse", listener: function): this
  • addListener(event: "Debugger.breakpointResolved", listener: function): this
  • addListener(event: "Debugger.paused", listener: function): this
  • addListener(event: "Debugger.resumed", listener: function): this
  • addListener(event: "Console.messageAdded", listener: function): this
  • addListener(event: "Profiler.consoleProfileStarted", listener: function): this
  • addListener(event: "Profiler.consoleProfileFinished", listener: function): this
  • addListener(event: "HeapProfiler.addHeapSnapshotChunk", listener: function): this
  • addListener(event: "HeapProfiler.resetProfiles", listener: function): this
  • addListener(event: "HeapProfiler.reportHeapSnapshotProgress", listener: function): this
  • addListener(event: "HeapProfiler.lastSeenObjectId", listener: function): this
  • addListener(event: "HeapProfiler.heapStatsUpdate", listener: function): this
  • addListener(event: "NodeTracing.dataCollected", listener: function): this
  • addListener(event: "NodeTracing.tracingComplete", listener: function): this
  • addListener(event: "NodeWorker.attachedToWorker", listener: function): this
  • addListener(event: "NodeWorker.detachedFromWorker", listener: function): this
  • addListener(event: "NodeWorker.receivedMessageFromWorker", listener: function): this
  • addListener(event: "NodeRuntime.waitingForDisconnect", listener: function): this

connect

  • connect(): void
  • Connects a session to the inspector back-end. An exception will be thrown if there is already a connected session established either through the API or by a front-end connected to the Inspector WebSocket port.

    Returns void

disconnect

  • disconnect(): void
  • Immediately close the session. All pending message callbacks will be called with an error. session.connect() will need to be called to be able to send messages again. Reconnected session will lose all inspector state, such as enabled agents or configured breakpoints.

    Returns void

emit

eventNames

  • eventNames(): Array<string | symbol>
  • Returns Array<string | symbol>

getMaxListeners

  • getMaxListeners(): number

listenerCount

  • listenerCount(event: string | symbol): number
  • Parameters

    • event: string | symbol

    Returns number

listeners

  • listeners(event: string | symbol): Function[]
  • Parameters

    • event: string | symbol

    Returns Function[]

off

  • off(event: string | symbol, listener: function): this
  • Parameters

    • event: string | symbol
    • listener: function
        • (...args: any[]): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns this

on

  • on(event: string, listener: function): this
  • on(event: "inspectorNotification", listener: function): this
  • on(event: "Runtime.executionContextCreated", listener: function): this
  • on(event: "Runtime.executionContextDestroyed", listener: function): this
  • on(event: "Runtime.executionContextsCleared", listener: function): this
  • on(event: "Runtime.exceptionThrown", listener: function): this
  • on(event: "Runtime.exceptionRevoked", listener: function): this
  • on(event: "Runtime.consoleAPICalled", listener: function): this
  • on(event: "Runtime.inspectRequested", listener: function): this
  • on(event: "Debugger.scriptParsed", listener: function): this
  • on(event: "Debugger.scriptFailedToParse", listener: function): this
  • on(event: "Debugger.breakpointResolved", listener: function): this
  • on(event: "Debugger.paused", listener: function): this
  • on(event: "Debugger.resumed", listener: function): this
  • on(event: "Console.messageAdded", listener: function): this
  • on(event: "Profiler.consoleProfileStarted", listener: function): this
  • on(event: "Profiler.consoleProfileFinished", listener: function): this
  • on(event: "HeapProfiler.addHeapSnapshotChunk", listener: function): this
  • on(event: "HeapProfiler.resetProfiles", listener: function): this
  • on(event: "HeapProfiler.reportHeapSnapshotProgress", listener: function): this
  • on(event: "HeapProfiler.lastSeenObjectId", listener: function): this
  • on(event: "HeapProfiler.heapStatsUpdate", listener: function): this
  • on(event: "NodeTracing.dataCollected", listener: function): this
  • on(event: "NodeTracing.tracingComplete", listener: function): this
  • on(event: "NodeWorker.attachedToWorker", listener: function): this
  • on(event: "NodeWorker.detachedFromWorker", listener: function): this
  • on(event: "NodeWorker.receivedMessageFromWorker", listener: function): this
  • on(event: "NodeRuntime.waitingForDisconnect", listener: function): this

once

  • once(event: string, listener: function): this
  • once(event: "inspectorNotification", listener: function): this
  • once(event: "Runtime.executionContextCreated", listener: function): this
  • once(event: "Runtime.executionContextDestroyed", listener: function): this
  • once(event: "Runtime.executionContextsCleared", listener: function): this
  • once(event: "Runtime.exceptionThrown", listener: function): this
  • once(event: "Runtime.exceptionRevoked", listener: function): this
  • once(event: "Runtime.consoleAPICalled", listener: function): this
  • once(event: "Runtime.inspectRequested", listener: function): this
  • once(event: "Debugger.scriptParsed", listener: function): this
  • once(event: "Debugger.scriptFailedToParse", listener: function): this
  • once(event: "Debugger.breakpointResolved", listener: function): this
  • once(event: "Debugger.paused", listener: function): this
  • once(event: "Debugger.resumed", listener: function): this
  • once(event: "Console.messageAdded", listener: function): this
  • once(event: "Profiler.consoleProfileStarted", listener: function): this
  • once(event: "Profiler.consoleProfileFinished", listener: function): this
  • once(event: "HeapProfiler.addHeapSnapshotChunk", listener: function): this
  • once(event: "HeapProfiler.resetProfiles", listener: function): this
  • once(event: "HeapProfiler.reportHeapSnapshotProgress", listener: function): this
  • once(event: "HeapProfiler.lastSeenObjectId", listener: function): this
  • once(event: "HeapProfiler.heapStatsUpdate", listener: function): this
  • once(event: "NodeTracing.dataCollected", listener: function): this
  • once(event: "NodeTracing.tracingComplete", listener: function): this
  • once(event: "NodeWorker.attachedToWorker", listener: function): this
  • once(event: "NodeWorker.detachedFromWorker", listener: function): this
  • once(event: "NodeWorker.receivedMessageFromWorker", listener: function): this
  • once(event: "NodeRuntime.waitingForDisconnect", listener: function): this

post

  • post(method: string, params?: __type, callback?: function): void
  • post(method: string, callback?: function): void
  • post(method: "Schema.getDomains", callback?: function): void
  • post(method: "Runtime.evaluate", params?: EvaluateParameterType, callback?: function): void
  • post(method: "Runtime.evaluate", callback?: function): void
  • post(method: "Runtime.awaitPromise", params?: AwaitPromiseParameterType, callback?: function): void
  • post(method: "Runtime.awaitPromise", callback?: function): void
  • post(method: "Runtime.callFunctionOn", params?: CallFunctionOnParameterType, callback?: function): void
  • post(method: "Runtime.callFunctionOn", callback?: function): void
  • post(method: "Runtime.getProperties", params?: GetPropertiesParameterType, callback?: function): void
  • post(method: "Runtime.getProperties", callback?: function): void
  • post(method: "Runtime.releaseObject", params?: ReleaseObjectParameterType, callback?: function): void
  • post(method: "Runtime.releaseObject", callback?: function): void
  • post(method: "Runtime.releaseObjectGroup", params?: ReleaseObjectGroupParameterType, callback?: function): void
  • post(method: "Runtime.releaseObjectGroup", callback?: function): void
  • post(method: "Runtime.runIfWaitingForDebugger", callback?: function): void
  • post(method: "Runtime.enable", callback?: function): void
  • post(method: "Runtime.disable", callback?: function): void
  • post(method: "Runtime.discardConsoleEntries", callback?: function): void
  • post(method: "Runtime.setCustomObjectFormatterEnabled", params?: SetCustomObjectFormatterEnabledParameterType, callback?: function): void
  • post(method: "Runtime.setCustomObjectFormatterEnabled", callback?: function): void
  • post(method: "Runtime.compileScript", params?: CompileScriptParameterType, callback?: function): void
  • post(method: "Runtime.compileScript", callback?: function): void
  • post(method: "Runtime.runScript", params?: RunScriptParameterType, callback?: function): void
  • post(method: "Runtime.runScript", callback?: function): void
  • post(method: "Runtime.queryObjects", params?: QueryObjectsParameterType, callback?: function): void
  • post(method: "Runtime.queryObjects", callback?: function): void
  • post(method: "Runtime.globalLexicalScopeNames", params?: GlobalLexicalScopeNamesParameterType, callback?: function): void
  • post(method: "Runtime.globalLexicalScopeNames", callback?: function): void
  • post(method: "Debugger.enable", callback?: function): void
  • post(method: "Debugger.disable", callback?: function): void
  • post(method: "Debugger.setBreakpointsActive", params?: SetBreakpointsActiveParameterType, callback?: function): void
  • post(method: "Debugger.setBreakpointsActive", callback?: function): void
  • post(method: "Debugger.setSkipAllPauses", params?: SetSkipAllPausesParameterType, callback?: function): void
  • post(method: "Debugger.setSkipAllPauses", callback?: function): void
  • post(method: "Debugger.setBreakpointByUrl", params?: SetBreakpointByUrlParameterType, callback?: function): void
  • post(method: "Debugger.setBreakpointByUrl", callback?: function): void
  • post(method: "Debugger.setBreakpoint", params?: SetBreakpointParameterType, callback?: function): void
  • post(method: "Debugger.setBreakpoint", callback?: function): void
  • post(method: "Debugger.removeBreakpoint", params?: RemoveBreakpointParameterType, callback?: function): void
  • post(method: "Debugger.removeBreakpoint", callback?: function): void
  • post(method: "Debugger.getPossibleBreakpoints", params?: GetPossibleBreakpointsParameterType, callback?: function): void
  • post(method: "Debugger.getPossibleBreakpoints", callback?: function): void
  • post(method: "Debugger.continueToLocation", params?: ContinueToLocationParameterType, callback?: function): void
  • post(method: "Debugger.continueToLocation", callback?: function): void
  • post(method: "Debugger.pauseOnAsyncCall", params?: PauseOnAsyncCallParameterType, callback?: function): void
  • post(method: "Debugger.pauseOnAsyncCall", callback?: function): void
  • post(method: "Debugger.stepOver", callback?: function): void
  • post(method: "Debugger.stepInto", params?: StepIntoParameterType, callback?: function): void
  • post(method: "Debugger.stepInto", callback?: function): void
  • post(method: "Debugger.stepOut", callback?: function): void
  • post(method: "Debugger.pause", callback?: function): void
  • post(method: "Debugger.scheduleStepIntoAsync", callback?: function): void
  • post(method: "Debugger.resume", callback?: function): void
  • post(method: "Debugger.getStackTrace", params?: GetStackTraceParameterType, callback?: function): void
  • post(method: "Debugger.getStackTrace", callback?: function): void
  • post(method: "Debugger.searchInContent", params?: SearchInContentParameterType, callback?: function): void
  • post(method: "Debugger.searchInContent", callback?: function): void
  • post(method: "Debugger.setScriptSource", params?: SetScriptSourceParameterType, callback?: function): void
  • post(method: "Debugger.setScriptSource", callback?: function): void
  • post(method: "Debugger.restartFrame", params?: RestartFrameParameterType, callback?: function): void
  • post(method: "Debugger.restartFrame", callback?: function): void
  • post(method: "Debugger.getScriptSource", params?: GetScriptSourceParameterType, callback?: function): void
  • post(method: "Debugger.getScriptSource", callback?: function): void
  • post(method: "Debugger.setPauseOnExceptions", params?: SetPauseOnExceptionsParameterType, callback?: function): void
  • post(method: "Debugger.setPauseOnExceptions", callback?: function): void
  • post(method: "Debugger.evaluateOnCallFrame", params?: EvaluateOnCallFrameParameterType, callback?: function): void
  • post(method: "Debugger.evaluateOnCallFrame", callback?: function): void
  • post(method: "Debugger.setVariableValue", params?: SetVariableValueParameterType, callback?: function): void
  • post(method: "Debugger.setVariableValue", callback?: function): void
  • post(method: "Debugger.setReturnValue", params?: SetReturnValueParameterType, callback?: function): void
  • post(method: "Debugger.setReturnValue", callback?: function): void
  • post(method: "Debugger.setAsyncCallStackDepth", params?: SetAsyncCallStackDepthParameterType, callback?: function): void
  • post(method: "Debugger.setAsyncCallStackDepth", callback?: function): void
  • post(method: "Debugger.setBlackboxPatterns", params?: SetBlackboxPatternsParameterType, callback?: function): void
  • post(method: "Debugger.setBlackboxPatterns", callback?: function): void
  • post(method: "Debugger.setBlackboxedRanges", params?: SetBlackboxedRangesParameterType, callback?: function): void
  • post(method: "Debugger.setBlackboxedRanges", callback?: function): void
  • post(method: "Console.enable", callback?: function): void
  • post(method: "Console.disable", callback?: function): void
  • post(method: "Console.clearMessages", callback?: function): void
  • post(method: "Profiler.enable", callback?: function): void
  • post(method: "Profiler.disable", callback?: function): void
  • post(method: "Profiler.setSamplingInterval", params?: SetSamplingIntervalParameterType, callback?: function): void
  • post(method: "Profiler.setSamplingInterval", callback?: function): void
  • post(method: "Profiler.start", callback?: function): void
  • post(method: "Profiler.stop", callback?: function): void
  • post(method: "Profiler.startPreciseCoverage", params?: StartPreciseCoverageParameterType, callback?: function): void
  • post(method: "Profiler.startPreciseCoverage", callback?: function): void
  • post(method: "Profiler.stopPreciseCoverage", callback?: function): void
  • post(method: "Profiler.takePreciseCoverage", callback?: function): void
  • post(method: "Profiler.getBestEffortCoverage", callback?: function): void
  • post(method: "Profiler.startTypeProfile", callback?: function): void
  • post(method: "Profiler.stopTypeProfile", callback?: function): void
  • post(method: "Profiler.takeTypeProfile", callback?: function): void
  • post(method: "HeapProfiler.enable", callback?: function): void
  • post(method: "HeapProfiler.disable", callback?: function): void
  • post(method: "HeapProfiler.startTrackingHeapObjects", params?: StartTrackingHeapObjectsParameterType, callback?: function): void
  • post(method: "HeapProfiler.startTrackingHeapObjects", callback?: function): void
  • post(method: "HeapProfiler.stopTrackingHeapObjects", params?: StopTrackingHeapObjectsParameterType, callback?: function): void
  • post(method: "HeapProfiler.stopTrackingHeapObjects", callback?: function): void
  • post(method: "HeapProfiler.takeHeapSnapshot", params?: TakeHeapSnapshotParameterType, callback?: function): void
  • post(method: "HeapProfiler.takeHeapSnapshot", callback?: function): void
  • post(method: "HeapProfiler.collectGarbage", callback?: function): void
  • post(method: "HeapProfiler.getObjectByHeapObjectId", params?: GetObjectByHeapObjectIdParameterType, callback?: function): void
  • post(method: "HeapProfiler.getObjectByHeapObjectId", callback?: function): void
  • post(method: "HeapProfiler.addInspectedHeapObject", params?: AddInspectedHeapObjectParameterType, callback?: function): void
  • post(method: "HeapProfiler.addInspectedHeapObject", callback?: function): void
  • post(method: "HeapProfiler.getHeapObjectId", params?: GetHeapObjectIdParameterType, callback?: function): void
  • post(method: "HeapProfiler.getHeapObjectId", callback?: function): void
  • post(method: "HeapProfiler.startSampling", params?: StartSamplingParameterType, callback?: function): void
  • post(method: "HeapProfiler.startSampling", callback?: function): void
  • post(method: "HeapProfiler.stopSampling", callback?: function): void
  • post(method: "HeapProfiler.getSamplingProfile", callback?: function): void
  • post(method: "NodeTracing.getCategories", callback?: function): void
  • post(method: "NodeTracing.start", params?: StartParameterType, callback?: function): void
  • post(method: "NodeTracing.start", callback?: function): void
  • post(method: "NodeTracing.stop", callback?: function): void
  • post(method: "NodeWorker.sendMessageToWorker", params?: SendMessageToWorkerParameterType, callback?: function): void
  • post(method: "NodeWorker.sendMessageToWorker", callback?: function): void
  • post(method: "NodeWorker.enable", params?: EnableParameterType, callback?: function): void
  • post(method: "NodeWorker.enable", callback?: function): void
  • post(method: "NodeWorker.disable", callback?: function): void
  • post(method: "NodeWorker.detach", params?: DetachParameterType, callback?: function): void
  • post(method: "NodeWorker.detach", callback?: function): void
  • post(method: "NodeRuntime.notifyWhenWaitingForDisconnect", params?: NotifyWhenWaitingForDisconnectParameterType, callback?: function): void
  • post(method: "NodeRuntime.notifyWhenWaitingForDisconnect", callback?: function): void
  • Posts a message to the inspector back-end. callback will be notified when a response is received. callback is a function that accepts two optional arguments - error and message-specific result.

    Parameters

    • method: string
    • Optional params: __type
    • Optional callback: function
        • (err: Error | null, params?: __type): void
        • Parameters

          • err: Error | null
          • Optional params: __type

          Returns void

    Returns void

  • Parameters

    • method: string
    • Optional callback: function
        • (err: Error | null, params?: __type): void
        • Parameters

          • err: Error | null
          • Optional params: __type

          Returns void

    Returns void

  • Returns supported domains.

    Parameters

    Returns void

  • Evaluates expression on global object.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Add handler to promise with given promise object id.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Calls function with given declaration on the given object. Object group of the result is inherited from the target object.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Returns properties of a given object. Object group of the result is inherited from the target object.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Releases remote object with given id.

    Parameters

    Returns void

  • Parameters

    • method: "Runtime.releaseObject"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Releases all remote objects that belong to a given group.

    Parameters

    Returns void

  • Parameters

    • method: "Runtime.releaseObjectGroup"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Tells inspected instance to run if it was waiting for debugger to attach.

    Parameters

    • method: "Runtime.runIfWaitingForDebugger"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Enables reporting of execution contexts creation by means of executionContextCreated event. When the reporting gets enabled the event will be sent immediately for each existing execution context.

    Parameters

    • method: "Runtime.enable"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Disables reporting of execution contexts creation.

    Parameters

    • method: "Runtime.disable"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Discards collected exceptions and console API calls.

    Parameters

    • method: "Runtime.discardConsoleEntries"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • experimental

    Parameters

    Returns void

  • Parameters

    • method: "Runtime.setCustomObjectFormatterEnabled"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Compiles expression.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Runs script with given id in a given context.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Parameters

    Returns void

  • Parameters

    Returns void

  • Returns all let, const and class variables from global scope.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Enables debugger for the given page. Clients should not assume that the debugging has been enabled until the result for this command is received.

    Parameters

    Returns void

  • Disables debugger for given page.

    Parameters

    • method: "Debugger.disable"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Activates / deactivates all breakpoints on the page.

    Parameters

    Returns void

  • Parameters

    • method: "Debugger.setBreakpointsActive"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Makes page not interrupt on any pauses (breakpoint, exception, dom exception etc).

    Parameters

    Returns void

  • Parameters

    • method: "Debugger.setSkipAllPauses"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Sets JavaScript breakpoint at given location specified either by URL or URL regex. Once this command is issued, all existing parsed scripts will have breakpoints resolved and returned in locations property. Further matching script parsing will result in subsequent breakpointResolved events issued. This logical breakpoint will survive page reloads.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Sets JavaScript breakpoint at a given location.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Removes JavaScript breakpoint.

    Parameters

    Returns void

  • Parameters

    • method: "Debugger.removeBreakpoint"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Returns possible locations for breakpoint. scriptId in start and end range locations should be the same.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Continues execution until specific location is reached.

    Parameters

    Returns void

  • Parameters

    • method: "Debugger.continueToLocation"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • experimental

    Parameters

    Returns void

  • Parameters

    • method: "Debugger.pauseOnAsyncCall"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Steps over the statement.

    Parameters

    • method: "Debugger.stepOver"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Steps into the function call.

    Parameters

    • method: "Debugger.stepInto"
    • Optional params: StepIntoParameterType
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    • method: "Debugger.stepInto"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Steps out of the function call.

    Parameters

    • method: "Debugger.stepOut"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Stops on the next JavaScript statement.

    Parameters

    • method: "Debugger.pause"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • This method is deprecated - use Debugger.stepInto with breakOnAsyncCall and Debugger.pauseOnAsyncTask instead. Steps into next scheduled async task if any is scheduled before next pause. Returns success when async task is actually scheduled, returns error if no task were scheduled or another scheduleStepIntoAsync was called.

    experimental

    Parameters

    • method: "Debugger.scheduleStepIntoAsync"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Resumes JavaScript execution.

    Parameters

    • method: "Debugger.resume"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Returns stack trace with given stackTraceId.

    experimental

    Parameters

    Returns void

  • Parameters

    Returns void

  • Searches for given string in script content.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Edits JavaScript source live.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Restarts particular call frame from the beginning.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Returns source for the script with given id.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Defines pause on exceptions state. Can be set to stop on all exceptions, uncaught exceptions or no exceptions. Initial pause on exceptions state is none.

    Parameters

    Returns void

  • Parameters

    • method: "Debugger.setPauseOnExceptions"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Evaluates expression on a given call frame.

    Parameters

    Returns void

  • Parameters

    Returns void

  • Changes value of variable in a callframe. Object-based scopes are not supported and must be mutated manually.

    Parameters

    Returns void

  • Parameters

    • method: "Debugger.setVariableValue"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Changes return value in top frame. Available only at return break position.

    experimental

    Parameters

    Returns void

  • Parameters

    • method: "Debugger.setReturnValue"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Enables or disables async call stacks tracking.

    Parameters

    Returns void

  • Parameters

    • method: "Debugger.setAsyncCallStackDepth"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Replace previous blackbox patterns with passed ones. Forces backend to skip stepping/pausing in scripts with url matching one of the patterns. VM will try to leave blackboxed script by performing 'step in' several times, finally resorting to 'step out' if unsuccessful.

    experimental

    Parameters

    Returns void

  • Parameters

    • method: "Debugger.setBlackboxPatterns"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Makes backend skip steps in the script in blackboxed ranges. VM will try leave blacklisted scripts by performing 'step in' several times, finally resorting to 'step out' if unsuccessful. Positions array contains positions where blackbox state is changed. First interval isn't blackboxed. Array should be sorted.

    experimental

    Parameters

    Returns void

  • Parameters

    • method: "Debugger.setBlackboxedRanges"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Enables console domain, sends the messages collected so far to the client by means of the messageAdded notification.

    Parameters

    • method: "Console.enable"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Disables console domain, prevents further console messages from being reported to the client.

    Parameters

    • method: "Console.disable"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Does nothing.

    Parameters

    • method: "Console.clearMessages"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    • method: "Profiler.enable"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    • method: "Profiler.disable"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Changes CPU profiler sampling interval. Must be called before CPU profiles recording started.

    Parameters

    Returns void

  • Parameters

    • method: "Profiler.setSamplingInterval"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    • method: "Profiler.start"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    Returns void

  • Enable precise code coverage. Coverage data for JavaScript executed before enabling precise code coverage may be incomplete. Enabling prevents running optimized code and resets execution counters.

    Parameters

    Returns void

  • Parameters

    • method: "Profiler.startPreciseCoverage"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Disable precise code coverage. Disabling releases unnecessary execution count records and allows executing optimized code.

    Parameters

    • method: "Profiler.stopPreciseCoverage"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Collect coverage data for the current isolate, and resets execution counters. Precise code coverage needs to have started.

    Parameters

    Returns void

  • Collect coverage data for the current isolate. The coverage data may be incomplete due to garbage collection.

    Parameters

    Returns void

  • Enable type profile.

    experimental

    Parameters

    • method: "Profiler.startTypeProfile"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Disable type profile. Disabling releases type profile data collected so far.

    experimental

    Parameters

    • method: "Profiler.stopTypeProfile"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Collect type profile.

    experimental

    Parameters

    Returns void

  • Parameters

    • method: "HeapProfiler.enable"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    • method: "HeapProfiler.disable"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    Returns void

  • Parameters

    • method: "HeapProfiler.startTrackingHeapObjects"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    Returns void

  • Parameters

    • method: "HeapProfiler.stopTrackingHeapObjects"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    Returns void

  • Parameters

    • method: "HeapProfiler.takeHeapSnapshot"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    • method: "HeapProfiler.collectGarbage"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    Returns void

  • Parameters

    Returns void

  • Enables console to refer to the node with given id via $x (see Command Line API for more details $x functions).

    Parameters

    Returns void

  • Parameters

    • method: "HeapProfiler.addInspectedHeapObject"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    Returns void

  • Parameters

    Returns void

  • Parameters

    Returns void

  • Parameters

    • method: "HeapProfiler.startSampling"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    Returns void

  • Parameters

    Returns void

  • Gets supported tracing categories.

    Parameters

    Returns void

  • Start trace events collection.

    Parameters

    • method: "NodeTracing.start"
    • Optional params: StartParameterType
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    • method: "NodeTracing.start"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Stop trace events collection. Remaining collected events will be sent as a sequence of dataCollected events followed by tracingComplete event.

    Parameters

    • method: "NodeTracing.stop"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Sends protocol message over session with given id.

    Parameters

    Returns void

  • Parameters

    • method: "NodeWorker.sendMessageToWorker"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Instructs the inspector to attach to running workers. Will also attach to new workers as they start

    Parameters

    • method: "NodeWorker.enable"
    • Optional params: EnableParameterType
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    • method: "NodeWorker.enable"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Detaches from all running workers and disables attaching to new workers as they are started.

    Parameters

    • method: "NodeWorker.disable"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Detached from the worker with given sessionId.

    Parameters

    • method: "NodeWorker.detach"
    • Optional params: DetachParameterType
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    • method: "NodeWorker.detach"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

  • Enable the NodeRuntime.waitingForDisconnect.

    Parameters

    Returns void

  • Parameters

    • method: "NodeRuntime.notifyWhenWaitingForDisconnect"
    • Optional callback: function
        • (err: Error | null): void
        • Parameters

          Returns void

    Returns void

prependListener

  • prependListener(event: string, listener: function): this
  • prependListener(event: "inspectorNotification", listener: function): this
  • prependListener(event: "Runtime.executionContextCreated", listener: function): this
  • prependListener(event: "Runtime.executionContextDestroyed", listener: function): this
  • prependListener(event: "Runtime.executionContextsCleared", listener: function): this
  • prependListener(event: "Runtime.exceptionThrown", listener: function): this
  • prependListener(event: "Runtime.exceptionRevoked", listener: function): this
  • prependListener(event: "Runtime.consoleAPICalled", listener: function): this
  • prependListener(event: "Runtime.inspectRequested", listener: function): this
  • prependListener(event: "Debugger.scriptParsed", listener: function): this
  • prependListener(event: "Debugger.scriptFailedToParse", listener: function): this
  • prependListener(event: "Debugger.breakpointResolved", listener: function): this
  • prependListener(event: "Debugger.paused", listener: function): this
  • prependListener(event: "Debugger.resumed", listener: function): this
  • prependListener(event: "Console.messageAdded", listener: function): this
  • prependListener(event: "Profiler.consoleProfileStarted", listener: function): this
  • prependListener(event: "Profiler.consoleProfileFinished", listener: function): this
  • prependListener(event: "HeapProfiler.addHeapSnapshotChunk", listener: function): this
  • prependListener(event: "HeapProfiler.resetProfiles", listener: function): this
  • prependListener(event: "HeapProfiler.reportHeapSnapshotProgress", listener: function): this
  • prependListener(event: "HeapProfiler.lastSeenObjectId", listener: function): this
  • prependListener(event: "HeapProfiler.heapStatsUpdate", listener: function): this
  • prependListener(event: "NodeTracing.dataCollected", listener: function): this
  • prependListener(event: "NodeTracing.tracingComplete", listener: function): this
  • prependListener(event: "NodeWorker.attachedToWorker", listener: function): this
  • prependListener(event: "NodeWorker.detachedFromWorker", listener: function): this
  • prependListener(event: "NodeWorker.receivedMessageFromWorker", listener: function): this
  • prependListener(event: "NodeRuntime.waitingForDisconnect", listener: function): this

prependOnceListener

  • prependOnceListener(event: string, listener: function): this
  • prependOnceListener(event: "inspectorNotification", listener: function): this
  • prependOnceListener(event: "Runtime.executionContextCreated", listener: function): this
  • prependOnceListener(event: "Runtime.executionContextDestroyed", listener: function): this
  • prependOnceListener(event: "Runtime.executionContextsCleared", listener: function): this
  • prependOnceListener(event: "Runtime.exceptionThrown", listener: function): this
  • prependOnceListener(event: "Runtime.exceptionRevoked", listener: function): this
  • prependOnceListener(event: "Runtime.consoleAPICalled", listener: function): this
  • prependOnceListener(event: "Runtime.inspectRequested", listener: function): this
  • prependOnceListener(event: "Debugger.scriptParsed", listener: function): this
  • prependOnceListener(event: "Debugger.scriptFailedToParse", listener: function): this
  • prependOnceListener(event: "Debugger.breakpointResolved", listener: function): this
  • prependOnceListener(event: "Debugger.paused", listener: function): this
  • prependOnceListener(event: "Debugger.resumed", listener: function): this
  • prependOnceListener(event: "Console.messageAdded", listener: function): this
  • prependOnceListener(event: "Profiler.consoleProfileStarted", listener: function): this
  • prependOnceListener(event: "Profiler.consoleProfileFinished", listener: function): this
  • prependOnceListener(event: "HeapProfiler.addHeapSnapshotChunk", listener: function): this
  • prependOnceListener(event: "HeapProfiler.resetProfiles", listener: function): this
  • prependOnceListener(event: "HeapProfiler.reportHeapSnapshotProgress", listener: function): this
  • prependOnceListener(event: "HeapProfiler.lastSeenObjectId", listener: function): this
  • prependOnceListener(event: "HeapProfiler.heapStatsUpdate", listener: function): this
  • prependOnceListener(event: "NodeTracing.dataCollected", listener: function): this
  • prependOnceListener(event: "NodeTracing.tracingComplete", listener: function): this
  • prependOnceListener(event: "NodeWorker.attachedToWorker", listener: function): this
  • prependOnceListener(event: "NodeWorker.detachedFromWorker", listener: function): this
  • prependOnceListener(event: "NodeWorker.receivedMessageFromWorker", listener: function): this
  • prependOnceListener(event: "NodeRuntime.waitingForDisconnect", listener: function): this

rawListeners

  • rawListeners(event: string | symbol): Function[]
  • Parameters

    • event: string | symbol

    Returns Function[]

removeAllListeners

  • removeAllListeners(event?: string | symbol): this
  • Parameters

    • Optional event: string | symbol

    Returns this

removeListener

  • removeListener(event: string | symbol, listener: function): this
  • Parameters

    • event: string | symbol
    • listener: function
        • (...args: any[]): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns this

setMaxListeners

  • setMaxListeners(n: number): this

Static listenerCount

  • listenerCount(emitter: EventEmitter, event: string | symbol): number
  • deprecated

    since v4.0.0

    Parameters

    Returns number

Static on

Static once

Generated using TypeDoc