[Vuejs]-Problem with component destruction in vue

0👍

In order to run code when the user closes the tab, you’ll need to attach a listener to the beforeUnload event. AFAIK, a component’s destroyed method is only called when a Vue instance destroys the component.

Leave a comment