GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Playwright
  • Docs
  • MCP
  • CLI
  • API
  • Node.js
  • Python
  • Java
  • .NET
  • API reference
  • Classes
  • APIRequestContext
  • APIResponse
  • Browser

This view

  • Original page
  • New address

GeezerVison is showing playwright.dev — Debugger | Playwright

This is unreleased documentation for Playwright Next version.
For up-to-date documentation, see the latest version (stable).
Version: Next

API for controlling the Playwright debugger. The debugger allows pausing script execution and inspecting the page. Obtain the debugger instance via browserContext.debugger.


Methods​

next​

Added in: v1.59 debugger.next

Resumes script execution and pauses again before the next action. Throws if the debugger is not paused.

Usage

await debugger.next();

Returns

  • Promise<void>#

pausedDetails​

Added in: v1.59 debugger.pausedDetails

Returns details about the currently paused call. Returns null if the debugger is not paused.

Usage

debugger.pausedDetails();

Returns

  • null | Object#
    • location Object

      • file string

      • line number (optional)

      • column number (optional)

    • title string


requestPause​

Added in: v1.59 debugger.requestPause

Configures the debugger to pause before the next action is executed.

Throws if the debugger is already paused. Use debugger.next() or debugger.runTo() to step while paused.

Note that page.pause() is equivalent to a "debugger" statement — it pauses execution at the call site immediately. On the contrary, debugger.requestPause() is equivalent to "pause on next statement" — it configures the debugger to pause before the next action is executed.

Usage

await debugger.requestPause();

Returns

  • Promise<void>#

resume​

Added in: v1.59 debugger.resume

Resumes script execution. Throws if the debugger is not paused.

Usage

await debugger.resume();

Returns

  • Promise<void>#

runTo​

Added in: v1.59 debugger.runTo

Resumes script execution and pauses when an action originates from the given source location. Throws if the debugger is not paused.

Usage

await debugger.runTo(location);

Arguments

  • location Object#

    • file string

    • line number (optional)

    • column number (optional)

    The source location to pause at.

Returns

  • Promise<void>#

Events​

on('pausedstatechanged')​

Added in: v1.59 debugger.on('pausedstatechanged')

Emitted when the debugger pauses or resumes.

Usage

debugger.on('pausedstatechanged', data => {});
  • Methods
    • next
    • pausedDetails
    • requestPause
    • resume
    • runTo
  • Events
    • on('pausedstatechanged')
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.