title: Error "element is detached from the DOM" after vising a link in a loop
body: <p>I am trying to do smoke testing by clicking links in a list. After first visit the test stops with following error.</p>
  
  <pre><code>CypressError: cy.click() failed because this element is detached from the DOM.
  
  &lt;a href="/link2"&gt;...&lt;/a&gt;
  
  Cypress requires elements be attached in the DOM to interact with them.
  
  The previous command that ran was:
  
  &gt; cy.wrap()
  </code></pre>
  
  <p>What do i do to hold on the element in the loop ?    </p>
  
  <pre><code>it('Click each link in the list', () =&gt; {
    cy.get('li a').each(($el, index, $list) =&gt; {
       cy.wrap($el).click();
       cy.go(-1);
    })
  })
  </code></pre>
  
  <p>The objective of the test is to check if all pages in the list come up without 404 errors. Following the html code</p>
  
  <pre><code>&lt;ul&gt;
     &lt;li&gt;&lt;a href="/link1"&gt;Link 1&lt;/a&gt;&lt;/li&gt;
     &lt;li&gt;&lt;a href="/link2"&gt;Link 2&lt;/a&gt;&lt;/li&gt;
     &lt;li&gt;&lt;a href="/link3"&gt;Link 3&lt;/a&gt;&lt;/li&gt;
  &lt;/ul&gt;
  </code></pre>