find
Finds the first descendant matching a selector.
Import:
import 'obsidian-test-mocks/setup';Signature:
function find(this: HTMLElement, selector: string): HTMLElementParameters:
| Parameter | Type | Description |
|---|---|---|
this |
HTMLElement | |
selector |
string | The CSS selector to match. |
Returns: HTMLElement — The first matching element. The mock throws when nothing matches.