My angular app works perfectly on my localhost:4200. Now I have deploy it to the server. The homepage looks okay. It redirect to error page due to invalid URL. The valid url of the page is this.
I get valid page if the url has pass two route params in my local but for some reason it is not working on live server.
const routes: Routes = [
{
path:":restaurantId/:mobileNo",
component: LandingComponent,
},
{
path:"",
component: LandingComponent,
canActivate: [AuthGuard]
},
{
path:"error",
component: ErrorComponent,
},
];
index.html
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Freshii</title>
<base href="/">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="icon" type="image/x-icon" href="favicon.ico">
</head>
<body>
<app-root></app-root>
</body>
</html>

ng build --prodng build --prod --base-href="http://dev.fobo.live"