[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: SerializableOrJSHandle[]): Promise;
```
## Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| pageFunction | Function \| string | |
| options | { timeout?: number; polling?: string \| number; } | |
| args | [SerializableOrJSHandle](./puppeteer.serializableorjshandle.md)\[\] | |
Returns:
Promise<[JSHandle](./puppeteer.jshandle.md)>