404 error on page refresh in angular 11 code example
Example: angular 404 on refresh
Use HashLocation strategy.
Add to top level module
import { HashLocationStrategy, LocationStrategy } from '@angular/common';
providers: [{provide: LocationStrategy, useClass: HashLocationStrategy}],