Skip to main content

Module target

Module target 

Source
Expand description

Supports additional targets discovery and allows to attach to them.

Structs§

ActivateTargetParams
Activates (focuses) the target.
ActivateTargetParamsBuilder
AttachToBrowserTargetParams
AttachToBrowserTargetReturns
Attaches to the browser target, only uses flat sessionId mode.
AttachToBrowserTargetReturnsBuilder
AttachToTargetParams
Attaches to the target with given id.
AttachToTargetParamsBuilder
AttachToTargetReturns
Attaches to the target with given id.
AttachToTargetReturnsBuilder
AutoAttachRelatedParams
Adds the specified target to the list of targets that will be monitored for any related target creation (such as child frames, child workers and new versions of service worker) and reported through ‘attachedToTarget’. The specified target is also auto-attached. This cancels the effect of any previous ‘setAutoAttach’ and is also cancelled by subsequent ‘setAutoAttach’. Only available at the Browser target.
AutoAttachRelatedParamsBuilder
CloseTargetParams
Closes the target. If the target is a page that gets closed too.
CloseTargetParamsBuilder
CloseTargetReturns
Closes the target. If the target is a page that gets closed too.
CloseTargetReturnsBuilder
CreateBrowserContextParams
Creates a new empty BrowserContext. Similar to an incognito profile but you can have more than one.
CreateBrowserContextParamsBuilder
CreateBrowserContextReturns
Creates a new empty BrowserContext. Similar to an incognito profile but you can have more than one.
CreateBrowserContextReturnsBuilder
CreateTargetParams
Creates a new page.
CreateTargetParamsBuilder
CreateTargetReturns
Creates a new page.
CreateTargetReturnsBuilder
DetachFromTargetParams
Detaches session with given id.
DetachFromTargetParamsBuilder
DisposeBrowserContextParams
Deletes a BrowserContext. All the belonging pages will be closed without calling their beforeunload hooks.
DisposeBrowserContextParamsBuilder
ExposeDevToolsProtocolParams
Inject object to the target’s main frame that provides a communication channel with browser target.
ExposeDevToolsProtocolParamsBuilder
FilterEntry
A filter used by target query/discovery/auto-attach operations.
FilterEntryBuilder
GetBrowserContextsParams
GetBrowserContextsReturns
Returns all browser contexts created with ‘Target.createBrowserContext’ method.
GetBrowserContextsReturnsBuilder
GetDevToolsTargetParams
Gets the targetId of the DevTools page target opened for the given target (if any).
GetDevToolsTargetParamsBuilder
GetDevToolsTargetReturns
Gets the targetId of the DevTools page target opened for the given target (if any).
GetDevToolsTargetReturnsBuilder
GetTargetInfoParams
Returns information about a target.
GetTargetInfoParamsBuilder
GetTargetInfoReturns
Returns information about a target.
GetTargetInfoReturnsBuilder
GetTargetsParams
Retrieves a list of available targets.
GetTargetsParamsBuilder
GetTargetsReturns
Retrieves a list of available targets.
GetTargetsReturnsBuilder
OpenDevToolsParams
Opens a DevTools window for the target.
OpenDevToolsParamsBuilder
OpenDevToolsReturns
Opens a DevTools window for the target.
OpenDevToolsReturnsBuilder
RemoteLocation
RemoteLocationBuilder
SendMessageToTargetParams
Sends protocol message over session with given id. Consider using flat mode instead; see commands attachToTarget, setAutoAttach, and crbug.com/991325.
SendMessageToTargetParamsBuilder
SetAutoAttachParams
Controls whether to automatically attach to new targets which are considered to be directly related to this one (for example, iframes or workers). When turned on, attaches to all existing related targets as well. When turned off, automatically detaches from all currently attached targets. This also clears all targets added by ‘autoAttachRelated’ from the list of targets to watch for creation of related targets. You might want to call this recursively for auto-attached targets to attach to all available targets.
SetAutoAttachParamsBuilder
SetDiscoverTargetsParams
Controls whether to discover available targets and notify via ‘targetCreated/targetInfoChanged/targetDestroyed’ events.
SetDiscoverTargetsParamsBuilder
SetRemoteLocationsParams
Enables target discovery for the specified locations, when ‘setDiscoverTargets’ was set to ‘true’.
SetRemoteLocationsParamsBuilder
TargetInfo
TargetInfoBuilder

Enums§

WindowState
The state of the target window.

Type Aliases§

SessionID
Unique identifier of attached debugging session.
TargetFilter
The entries in TargetFilter are matched sequentially against targets and the first entry that matches determines if the target is included or not, depending on the value of ‘exclude’ field in the entry. If filter is not specified, the one assumed is [{type: “browser”, exclude: true}, {type: “tab”, exclude: true}, {}] (i.e. include everything but ‘browser’ and ‘tab’).
TargetID