title: How to detect Browser Refresh using Angular
body: <p>In my current application, whenever the user clicks on the Refresh button on the Browser, the application is getting loaded again and re-directing the user to the Home Page. 
  I got a requirement to stay on the same page (without loading the application again). I have gone through many links in StackOverflow, but I could not find out an exact solution which I am looking. Any help will be appreciated.</p>
  
  <p>I am using angular 1.3.17 and $stateProvider for routing between the states. I am storing all the data in the $rootScope and whenever user clicks on refresh, $rootScope is getting destroyed and application has to be reloaded again</p>
  
  <p>My objective is to prevent app loading and load only the page which user is currently using.</p>