Why closing a page does not unmount the component
Closing the page will actually discard the main process/thread which handles the rendering of the web page. In that case,
there is actually no way of calling the unmounting method since the thread which calls that method is discarded.