puppeteer/website/versioned_docs/version-22.10.0/api/puppeteer.extensiontransport.md
release-please[bot] d963fcdd80
chore: release main (#12456)
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
2024-05-24 07:26:52 +00:00

1.6 KiB

sidebar_label
ExtensionTransport

ExtensionTransport class

Experimental ExtensionTransport allows establishing a connection via chrome.debugger API if Puppeteer runs in an extension. Since Chrome DevTools Protocol is restricted for extensions, the transport implements missing commands and events.

Signature:

export declare class ExtensionTransport implements ConnectionTransport

Implements: ConnectionTransport

Remarks

The constructor for this class is marked as internal. Third-party code should not call the constructor directly or create subclasses that extend the ExtensionTransport class.

Properties

Property

Modifiers

Type

Description

onclose

optional

() => void

onmessage

optional

(message: string) => void

Methods

Method

Modifiers

Description

close()

connectTab(tabId)

static

send(message)