I am running ndb to debug my puppeteer scripts. When I put a breakpoint and use console to make some evaluation on selection such as:
h1 = await page.$eval("h1", el => el.innerText);
I got as result an Promise
How can I retrieve the result ?
I tried:
await page.$eval("h1", el => el.innerText).then((response) => {
console.log(response);
});
with no success : got a Promise as well