title: How to destroy a JavaScript object?
body: <p>Recently, I came across one of my application which consumes too much memory and increasing by 10 MB/sec.</p>
  <p>So, I like to know how to destroy JavaScript object and variables so memory consumption stays down and my FF can't get destroyed.</p>
  <p>I am calling two of my scripts every 8 seconds without reloading the page.</p>
  <pre><code>function refresh() {
      $('#table_info').remove();
      $('#table').hide();
      if (refreshTimer) {
          clearTimeout(refreshTimer);
          refreshTimer = null ;
      }
      document.getElementById('refresh_topology').disabled=true; 
      $('&lt;div id=&quot;preload_xml&quot;&gt;&lt;/div&gt;').html('&lt;img src=&quot;pic/dataload.gif&quot; alt=&quot;loading data&quot; /&gt;&lt;h3&gt;Loading Data...&lt;/h3&gt;').prependTo($(&quot;#td_123&quot;));
      $(&quot;#topo&quot;).hide();
      $('#root').remove();
      show_topology();
  }
  </code></pre>
  <p>How can I see which variable cause <strong>Memory overhead</strong>, what's the method to stop the execution of that process?</p>