Works just like execute, only you can use Selenium selector strategies to pass html elements to the asynchronous function you wish to execute in the browser.

The asynchronous function fn will receive every resolved selector as an array of html elements, even if there is only one result, or no result. These arrays are the first arguments the function fn receives. If you pass an array of selectors, the resulting html element arrays are returned in the same order.

All arguments you append after function fn are added as the arguments after the html arrays. You can use any JSON value or a function as such an argument.




Param Type Details
selectors String/Array. single selector or array of selectors
script Function asynchronous function to get executed in the browser
argument1,…,argumentN …* arguments added to fn. Can be any JSON value or function