It would be nice if we can destroy timeline gracefully.
PVirie opened this issue · 3 comments
Timeline.terminate()
I am using svg.js to create a math tutorial web blog. It does the job nicely. Just one thing though..
Suppose that we have a script that uses svg.js, consider these conditions:
- The script uses a lot of persisting Runners (to make animations revertible).
- The script needs to replace and re-populate Timelines with those Runners.
For some reasons, javascript does not clean up Timelines properly and leaves a lot of occupying memory footprints.
I have been cleaning up Runners in Timelines manually. But it would be nice if you make an official support for this feature.
So instead of using this:
timeline._runners = [];
It would be nice if we can
timeline.terminate();
I will be happy if you could consider my request. Thank you in advance.
Will there be a release version for this?
I am sorry, I somehow forgot to publish all the fixes I made. I just released it:
https://github.com/svgdotjs/svg.js/releases/tag/3.2.1