title: Is there a way to check if the react component is unmounted?
body: <p>I have a usecase where i need to unmount my react component. But in some cases, the particular react component is unmounted by a different function.
  Hence, I need to check if the component is mounted before unmounting it.</p>