diff --git a/src/core/core.animator.js b/src/core/core.animator.js index 28565629e..1da383039 100644 --- a/src/core/core.animator.js +++ b/src/core/core.animator.js @@ -210,6 +210,14 @@ class Animator { anims.items = []; this._notify(chart, anims, Date.now(), 'complete'); } + + /** + * Remove chart from Animator + * @param {Chart} chart + */ + remove(chart) { + return this._charts.delete(chart); + } } const instance = new Animator(); diff --git a/src/core/core.controller.js b/src/core/core.controller.js index add55549b..aca27dc75 100644 --- a/src/core/core.controller.js +++ b/src/core/core.controller.js @@ -893,6 +893,7 @@ class Chart { let i, ilen; me.stop(); + Animator.remove(me); // dataset controllers need to cleanup associated data for (i = 0, ilen = me.data.datasets.length; i < ilen; ++i) {