title: How to wait for a complete page load, after a link was clicked in puppeteer?
body: <p>Let's say i use the page.click() function, to simulate a click on a link:</p>
  <pre><code>await page.click('.some_link')
  </code></pre>
  <p>In the new page rendered by the browser(full page load, not SPA), i want to use page.click() again, on some element. Problem is, that even though the button is being &quot;clicked&quot;(i see the element focused), <strong>the attached JS listener doesn't fire</strong>, which make me suspect that the click() function fires <strong>before the new page was completely loaded.</strong></p>
  <p>If i create a delay with setTimeOut, everything works.</p>
  <p>To make things short: how do i make sure that a new page was fully loaded, after a navigation was triggered? I tried playing around with page.waitForNavigation(), always getting a timeout error(from the docs, it's not even clear to me, when this function needs to be used).</p>