title: Does removing an iframe free up the memory taken by its JavaScript code?
body: <p>I think that <strong>parsed/evaluated JavaScript</strong>, <em>not objects created by that JavaScript upon execution, rather the space taken up by the code itself</em>, will remain in memory as long as you are on the page, even if you deleted the original <strong>script node</strong> from whence that JavaScript came. (Er, is that true?)</p>
  <p>However, I'm wondering -- if that JavaScript lives inside an <strong>iframe</strong>... and that iframe is deleted from the containing <strong>document's tree</strong>, and all references to that iframe element are nulled out, so that <strong>garbage collection</strong> should do its thing...  will the browser free up the memory taken by the evaluated script that was in that iframe?</p>