title: Using `"homepage"` in package.json, without messing up paths for localhost
body: <p>This question actually follows directly from my <a href="https://stackoverflow.com/a/43011112/3391108">answer</a> on a previous question.</p>
  
  <p>I added a <code>"homepage"</code> to my <code>package.json</code> because it is a React app that I hosted on Github Pages. The output of <code>npm run build</code> say that the <code>/build</code> directory can now be deployed, and it assumes the project is being hosted at <code>/project_name/</code>.</p>
  
  <p>But on localhost, the project is <em>not</em> being hosted at <code>/project_name/</code>, so the paths being requested for js and css are messed up (looking for <code>/project_name/static/...</code> instead of <code>/static/...</code>) and the app broken.</p>
  
  <p>How can one have the homepage field in package.json so that they can deploy to Github Pages (for example) while still develop locally with a working app?</p>