I have an angular 4 project and when I run it from localhost:4200/route-a, it works fine and when I refresh the browser, all works well as expected. However, when I
localhost:4200/route-a
As of Apache version 2.2.16, you can use the FallbackResource directive for this:
FallbackResource index.php
Check https://httpd.apache.org/docs/trunk/rewrite/remapping.html#fallback-resource