Set

Provides functionality to set properties like innerHTML, innerText, and value on elements in a web page.

Classes

Set

Methods

(async) run(selector, value, propertyopt) → {Promise.<void>}

Sets a property on an element using a unified selector string. Supports CSS selectors (default), and prefix-based strategies: 'id:myId', 'xpath://input', 'name:field', 'class:input-field'.
Parameters:
NameTypeAttributesDefaultDescription
selectorstringThe selector string for the element.
valuestringThe value to set.
propertystring<optional>
'value'The property to set: 'value', 'innerText', or 'innerHTML'.
Throws:
Throws an error if the element is not found.
Type
Error
Returns:
A promise that resolves when the property is set.
Type: 
Promise.<void>