browser_evaluate
Run a JavaScript function inside the current page to inspect or modify DOM state, optionally passing an element, and return a JSON-serializable value.
Instructions
Run a JavaScript function inside the page. Function source must be an arrow or function expression.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| target | No | If set, runs the function with this element as argument. | |
| element | No | ||
| function | Yes | JS function source: must be an arrow or function expression. Receives the page (or element) and returns a JSON-serializable value. |