It's unavoidable, and not strange at all. The first thing a browser generally does when you refresh is clear the window. (May depend on browser.)
jQuery Mobile avoids this on Ajax page changes, because it loads the new page into the same document and then does a CSS transition.
jQuery Mobile can't change the behavior of the browser when you refresh, though.
Why does the user have to "refresh the Javascripts"?
---
Edit: sorry, but I based my response on your summary line. Now that I've re-read you post, I am confused as to what the problem is. Is the problem that the page goes blank, or that the login page shows?
If you want more than some general advice, you will have to supply some details:
https://forum.jquery.com/topic/how-to-ask-for-jquery-mobile-help