That should not be a problem, the intention is that the new chart would force the previous to be removed (the same as calling .remove()
API call).
However, could you please test if having separate contains resolve the problem? In that case it would point to a bug in the library.
Another potential issue could be that the container ir invisible (display:none
or removed from the DOM) the the time when the chart is being created. Invisible containers sometimes create problems with the toolbar sizes etc.