[Home](./index.md) > [puppeteer](./puppeteer.md) > [Page](./puppeteer.page.md) > [waitForFunction](./puppeteer.page.waitforfunction.md) ## Page.waitForFunction() method Signature: ```typescript waitForFunction(pageFunction: Function | string, options?: { timeout?: number; polling?: string | number; }, ...args: unknown[]): Promise; ``` ## Parameters | Parameter | Type | Description | | --- | --- | --- | | pageFunction | Function \| string | | | options | { timeout?: number; polling?: string \| number; } | | | args | unknown\[\] | | Returns: Promise<[JSHandle](./puppeteer.jshandle.md)>