Angular / xng-breadcrumbs disappear on page reload

Viewed 520

I've added xng-breadcrumbs to my Angular 9 app. The breadcrumbs are empty after page reload. Minimal reproducible example is: this Stackblitz, where navigating to parent/child2 route renders the breadcrumbs but reloading wipes them out. What am I doing wrong?

1 Answers

You can resolve this issue by injecting the BreadcrumbService in your AppComponent:

export class AppComponent {

  constructor(private breadcrumbService: BreadcrumbService) {}

}
Related