Closed kamranayub closed 3 years ago
This is still an issue, if you don't click the play button. I think engine needs to call dispose
whenever stop
is called 😄
Workaround:
function cleanUpPlayButtons() {
const playButtons = document.querySelectorAll("#excalibur-play-root");
playButtons.forEach((playButton) => {
if (playButton.parentNode) {
playButton.parentNode.removeChild(playButton);
}
});
}
Steps to Reproduce
Expected Result
Play button should disappear/be cleaned up
Actual Result
Play button sticks around
Environment
Current Workaround
Target HTML element manually and delete from DOM