title: angular 4 application routing issues when deployed in cloud foundry
body: <p>I have a unique routing issue here, I have an angular application which works fine at my local, but when the application is deployed to the cloud foundry the routing simply does not work at all(it gives 404).</p>
  
  <p>Here is the code snippet of routing </p>
  
  <pre><code>import  { LocationStrategy,  PathLocationStrategy }  from  '@angular/common';
  const  appRoutes:  Routes  =   [{
    path:   '',
    component:  PageNotFoundComponent
   },
   {
    path:   'contents',
    component:  ContentsComponent
   },
   {
    path:   'sidebar',
    component:  SidebarComponent
   }
  ];
  </code></pre>
  
  <p>I am looking for these:</p>
  
  <p>routing conditions:</p>
  
  <ol>
  <li>Routing without hashing.</li>
  <li>Entering URL directly to the browser should navigate to the page.</li>
  <li>404 error should not be shown.</li>
  </ol>
  
  <p>Any suggestion?</p>