waypoints icon indicating copy to clipboard operation
waypoints copied to clipboard

Elements no longer in the DOM should be removed on refresh

Open patrick-mcdougle opened this issue 7 years ago • 1 comments

While poking around with removing elements, I noticed that elements that have been removed from the DOM still have their listeners and such stored in the Context.

These elements are never truly cleaned up and remain because there's a reference to them from the waypoint object.

Can we possibly remove the waypoints on refresh if we notice that the elements are no longer in the DOM?

patrick-mcdougle avatar Mar 06 '17 20:03 patrick-mcdougle

Here's an untested patch: https://gist.github.com/patrick-mcdougle/0d72e18f9f52cc586a6c025f7ab6745f/revisions

patrick-mcdougle avatar Mar 06 '17 20:03 patrick-mcdougle