Leave meeting and close SDK in Web SPA

Hi,
I’m currently using meetingsdk in a VueJS application.

I’ve successfully connected to the meeting but there’s a problem:

If the user leaves the meeting route, being a SPA, there’s no window document reloading, so the embed element keeps showing in the application, even if I execute ZoomMtg.leaveMeeting.

If the user clicks on the “Leave meeting” button, it works fine, but there’s no way to programmatically leave the meeting and remove the sdk elements from the DOM.