Angular gets 404 after refresh when using Path Location Strategy
If you are using path location strategy for routes in Angular, you might notice that after refreshing a secondary page, you get a 404 error.
This is because the path doesn’t really exist on the server. You need to redirect it to your site Angular root page and then it can take care of the routing.
This article linked here has code for the .htaccess file in Apache to perform this redirect.
The RewriteCond checks if assets exists or not. If not, redirect to root page.