stevenrskelton / sortable-table

Polymer Web Component that generates a sortable <table> from inlined or AJAX JSON, JSON5, and arrays.
https://stevenrskelton.github.io/sortable-table/
MIT License
196 stars 37 forks source link

Memory leaks while refreshing data #11

Open rpgraham84 opened 10 years ago

rpgraham84 commented 10 years ago

If you go to http://files.stevenskelton.ca/sortable-table/examples/refreshing-data.html and just leave the tab open for a few hours, you'll eventually crash your Chromium tab.

I was making my own page using and while working with a large dataset, noticed that there is absolutely no way to prevent memory usage from getting out of control (on my page it happened rather quickly). As you throw entries on to your dataset, or replace the dataset entirely, I think events are being bound and never nullified when the data is replaced, and thus, while no handles may remain to the old dataset, they live on in memory without being garbage collected.

stevenrskelton commented 10 years ago

Thanks for pointing this out. My hope is this is an Observe.js reference preventing cleanup; I'll definitely take a look and try to track it down.

MetaMemoryT commented 9 years ago

:+1: this is an important bug