Optional Parameters While Routing angular2 [duplicate]
问题 This question already has answers here : Angular 2 optional route parameter (10 answers) Closed 3 years ago . How to define optional parameters in routing of angular2.my routing configuration like this: <a [routerLink]="['../abc',{xyz: blabla}]"> and <a [routerLink]="['../abc']"> { path: '/abc/:xyz', component: abc, name: 'abc' }, // Here i want xyz as optional perameter so the problem is whenever i am using first method with parameter blabla it works fine because at the time of routing i