We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I Have the following routes
/projects/ /projects/:projectId /projects/:projectId/fields /projects/:projectId/fields/:fieldId
I've successfully replaced the projectId with a project name in the breadcrumb
Projects / Project Name Projects / Project Name / Fields Projects / Project Name / Fields / Field ID
by doing
import {Component, OnInit, ViewEncapsulation} from '@angular/core'; import {BreadcrumbService} from 'ng2-breadcrumb/bundles/components/breadcrumbService'; @Component({ selector: 'app-dashboard', templateUrl: './dashboard.component.html', styleUrls: ['./dashboard.component.css'], encapsulation: ViewEncapsulation.None, }) export class DashboardComponent implements OnInit { /** * Regex for UUID: [0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12} * @param {BreadcrumbService} breadcrumbService */ constructor(private breadcrumbService: BreadcrumbService) { breadcrumbService.addFriendlyNameForRoute('/projects', 'Projects'); breadcrumbService.addCallbackForRouteRegex('^/projects/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$', this.getNameForProject); breadcrumbService.addFriendlyNameForRouteRegex('^/projects/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/fields', 'Fields'); } ngOnInit() { } getNameForProject(projectId: string): string { console.log('getNameForProject', projectId); return 'Project Name'; } }
But I'm unable to replace the fieldId as well. My goal is to create a breadcrumb like this:
Project / Project Name / Fields / Field Name
Do you have any documentation about this?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I Have the following routes
I've successfully replaced the projectId with a project name in the breadcrumb
by doing
But I'm unable to replace the fieldId as well. My goal is to create a breadcrumb like this:
Do you have any documentation about this?
The text was updated successfully, but these errors were encountered: