Hello guys, the Breadcrumb observable is not working, I can't find the problem.
I follow the examples and did the same but the handler is not detecting setItems
on my new custom page component i already did:
constructor(private breadcrumbService: AppBreadcrumbService) {
this.breadcrumbService.setItems([
{ label: 'Operaciones' },
{ label: 'Emitir Factura', routerLink: [`/custom`] }
]);
}
on the app.breadcrumb.component.ts the subscribe is not working, the items is never set:
this.subscription = this.breadcrumbService.itemsHandler.subscribe(response => {
this.items = response;
console.log('breadcrumb.items', this.items); //never show
});
on the app.main.component.html is already:
<div class="layout-main">
<app-breadcrumb></app-breadcrumb>
<div class="layout-content">
<router-outlet></router-outlet>
</div>
<app-footer></app-footer>
</div>
Breadcrumb observable not working (setItems)
Forum rules
Please note that response time for technical support is within 3-5 business days.
Please note that response time for technical support is within 3-5 business days.
Hello my friend, there is no error in the console my pages components works fine
I use a custom PrimeNg module to group PrimeNg components/services
I import this custom PrimeNg module on my App module
app.main.component.html
app.breadcrumb.component.html
app.breadcrumb.component.ts
app.breadcrumb.service.ts
app-routing.module.ts
I use a custom PrimeNg module to group PrimeNg components/services
I import this custom PrimeNg module on my App module
app.main.component.html
app.breadcrumb.component.html
app.breadcrumb.component.ts
app.breadcrumb.service.ts
app-routing.module.ts
-
- Information
-
Who is online
Users browsing this forum: No registered users and 7 guests