how to unite cheerio with puppeteer so he can click on elements

104 Views Asked by At

I tried cheerio to find the element and if the element is found then he has to click but I don't know what to do with the puppeteer combination, the button I want to click is in the 3rd pict

    await page.waitForTimeout(10000)
    const contentHTML = await page.content();
    const $ = cheerio.load(contentHTML);
    const outerHTML = $('<button class="sc-nkuzb1-0 sc-d5trka-0 dsOMxw button" data-theme="home.verifyButton">Authenticate</button>').prop('innerText');  
    console.log(outerHTML);

enter image description here

enter image description here

0

There are 0 best solutions below