title: Create react app breaks after deployment on refresh 404 with Nginx
body: <p>I am using create-react-app, it works fine on my local, with no issues at all. When I have it deployed on IBM Cloud, after login, when I refresh the page it gives <strong>404 not found error</strong> It was working fine earlier, not sure what happened. </p>
  
  <p>I saw many related ques, The things I tried to solve and didn't work are following </p>
  
  <p><strong>1.</strong> <strong>Created a static.json</strong></p>
  
  <pre><code>{
    "root": "build/",
    "routes": {
      "/**": "index.html"
    }
  }
  </code></pre>
  
  <p><strong>2. I have this setup</strong></p>
  
  <pre><code>devServer: {
      historyApiFallback: true,
      contentBase: './',
      hot: true
    },
  </code></pre>
  
  <p><strong>3. I tried adding  around my Routers, didn't work</strong></p>
  
  <pre><code>import React, { Component } from 'react';
  import styled from 'styled-components';
  import { BrowserRouter as Router, Route, Switch } from 'react-router-dom';
  
      class App extends Component {
        render() {
          return (
            &lt;&gt;
              &lt;Router&gt;
                &lt;Switch&gt;
                  &lt;Route exact path="/" component={SignUp} /&gt;
                  &lt;Route path="/some" component={Some} /&gt;
                &lt;/Switch&gt;
              &lt;/Router&gt;
              &lt;/&gt;
          );
        }
      }
  
      export default App;
  </code></pre>
  
  <p><strong>4. I tried to add the following</strong> </p>
  
  <pre><code>import { HashRouter } from 'react-router-dom'
  
  &lt;HashRouter&gt;
    &lt;App/&gt;
  &lt;/HashRouter&gt;
  </code></pre>
  
  <p>None of these seem to work for me. Any suggestions</p>