title: Chrome extension login best practices
body: <p>I'm creating a Chrome extension popup and need login. For now, I will make my own authentication with a username and password, but what are best practices within an extension?</p>
  
  <p>Here are my thoughts:</p>
  
  <ul>
  <li>I will make the login against a remote server using a post. </li>
  <li>Get a token back which I will keep in local storage for an amount of time.</li>
  <li>The popup should also have a register inside it</li>
  </ul>
  
  <p>Is it good to keep it all inside the extension? This is where I want my users to be, and not in some website to register and so on. </p>
  
  <p>The change from login to "home page" or the registration page, should this be done with messaging?</p>