I use angular 6.
I have ListComponent which show list of products.
my routing
{
path: ('list/:category/:subcategory'),
component: ListComponent
}
a tag
<a class="link" [routerLink]="['/list/' + item.titleEn ]">
{{ item.title }}
</a>
<a class="sub-link" [routerLink]="['/list/' + item.titleEn + '/' + itemSub.titleEn ]"
{{ itemSub.title }}
</a>
now, when i click "/list/car/bmw" in HomeComponent (/home), that's worked and render ListComponent. but when i click "/list/car/bmw" in ListComponent (/list/car/benz), that's not working and not render ListComponent.