View Source API Reference playwright v1.49.1-alpha.1
Modules
Playwright
launches and manages with Playwright browser-server instances.
This API is used for the Web API testing. You can use it to trigger API endpoints, configure micro-services, prepare environment or the server to your e2e test.
A Playwright.Browser
instance is created via
Playwright.BrowserContext
provides a way to operate multiple independent
browser sessions.
Playwright.BrowserType
provides functions to launch a specific browser
instance or connect to an existing one.
Playwright.ConsoleMessage
instances are dispatched by page and handled via
Playwright.Page.on/3
for the :console
event type.
ElementHandle
represents an in-page DOM element.
At any point of time, Playwright.Page
exposes its current frame tree via
the Playwright.Page.main_frame/1
and Playwright.Frame.child_frames/1
functions.
Playwright.JSHandle
represents an in-page JavaScript object. JSHandles
can be created with Playwright.Page.evaluate_handle/3
.
Locators are the central piece of Playwright's auto-waiting and retry-ability.
In a nutshell, locators represent a way to find element(s) on the page at any
moment. A locator may be created with the Page.locator/2
function.
Page
provides methods to interact with a single tab in a
Playwright.Browser
, or an extension background page
in Chromium.
Playwright.Page.Accessibility
provides functions for inspecting Chromium's accessibility tree.
Keyboard
provides an API for managing a virtual keyboard. The high level API
is keyboard.type()
, which takes raw characters and generates proper
keydown
, keypress
/input
, and keyup
events on your page.
Playwright.Request
represents a request for a network resource.
...
A wrapper to the Playwright Javascript CLI
Provides storage and management of ChannelOwner instances.
Configuration for Playwright.
Use PlaywrightTest.Case
in an ExUnit test module to start a Playwright server and put it into the test context.
Mix Tasks
Installs Playwright browsers.