Home > other >  Angular / xng-breadcrumbs disappear on page reload
Angular / xng-breadcrumbs disappear on page reload

Time:11-24

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?

CodePudding user response:

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

export class AppComponent {

  constructor(private breadcrumbService: BreadcrumbService) {}

}
  • Related