Skip to content

Latest commit

 

History

History
28 lines (16 loc) · 838 Bytes

puppeteer.page._.md

File metadata and controls

28 lines (16 loc) · 838 Bytes

Home > puppeteer > Page > $

Page.$() method

Runs document.querySelector within the page. If no element matches the selector, the return value resolves to null.

Signature:

$(selector: string): Promise<ElementHandle | null>;

Parameters

Parameter Type Description
selector string A selector to query page for.

Returns:

Promise<ElementHandle | null>

Remarks

Shortcut for Page.mainFrame().$(selector).