Function typeByXPath

  • Types into a form field by Xpath, after the existing text.

    Parameters

    • ctx: Context

      Context object.

    • selector: string

      Xpath selector.

    • value: string

      A text to type into field.

    • options: TypeOptions = {}

    Returns Promise<void>

    Remarks

    Triggers an event for each character. If you want to clear the field first, use the helper "fillByXPath".

    Example

    await typeByXPath(ctx, '//input[@id="message"]', 'Hello');
    

    Example

    await typeByXPath(ctx, '//input[@id="message"]', 'Hello', {
    delay: 500,
    clear: true,
    blur: true,
    });

Generated using TypeDoc