UNPKG

@luminati-io/webdriverio8

Version:

Next-gen browser and mobile automation test framework for Node.js

25 lines 780 B
/** * * Returns the previous sibling element of the selected DOM-element. * * <example> :index.html <div class="parent"> <p>Sibling One</p> <p>Sibling Two</p> <p>Sibling Three</p> </div> :previousElement.js it('should get text from previous sibling element', async () => { const elem = await $$('p'); const previousElem = await elem[1].previousElement() console.log(await previousElem.getText()); // outputs: "Sibling One" }); * </example> * * @alias element.previousElement * @return {Element} * @type utility */ export declare function previousElement(this: WebdriverIO.Element): import("../../types.js").ChainablePromiseElement<WebdriverIO.Element>; //# sourceMappingURL=previousElement.d.ts.map