const { Builder, By, Key, until } = require("selenium-webdriver");
(async() => {
let driver = await new Builder().forBrowser("chrome").build();
await driver.get("http://localhost:5001/");
let pendingElements = driver.findElements(By.className("item"));
pendingElements.then(function(elements) {
let pendingHtml = elements.map(function(elem) {
return elem.getText();
});
Promise.all(pendingHtml).then(function(allHtml) {
console.log(allHtml);
});
});
})();
Замените
http://localhost:5001/ на адрес своей страницы.