API#
nz-breadcrumb#
Property | Description | Type | Default |
---|---|---|---|
[nzSeparator] |
Custom separator | string | TemplateRef<void> |
'/' |
[nzAutoGenerate] |
Auto generate breadcrumb | boolean |
false |
[nzRouteLabel] |
Name of property that determines displayed text in routing config. It should be used when nzAutoGenerate is true |
string |
'breadcrumb' |
Using [nzAutoGenerate]
by configuring data
like this:
{
path: '/path',
component: SomeComponent,
data: {
breadcrumb: 'Display Name'
}
}
For lazy loading moduels, you should write data
in parent module like this:
{
path: 'first',
loadChildren: './first/first.module#FirstModule',
data: {
breadcrumb: 'First'
},
}
use nzRouteLabel
to custom data
breadcrumb label:
<nz-breadcrumb [nzAutoGenerate]="true" [nzRouteLabel]="'customBreadcrumb'"></nz-breadcrumb>
{
path: 'path',
component: SomeComponent,
data: {
customBreadcrumb: 'Display Name'
}
}
近期评论