Skip to content

BreadcrumbTagHelper

StrutTower edited this page Feb 27, 2026 · 4 revisions

Tag helper for rendering Bootstrap's breadcrumbs.

Deprecation Warning

breadcrumb-item has been changed to breadcrumb breadcrumb-item-home has been changed to breadcrumb-home

The old tag helpers will still work but the link to display in red as a warning to update to the new syntax only if a debugger is currently attached.

Usage

<breadcrumbs>
    <breadcrumb-home />
    <breadcrumb asp-action="Test" asp-controller="Home" asp-area="">Test</breadcrumb>
    <breadcrumb>Current Page</breadcrumb>
</breadcrumbs>

Breadcrumb Attributes

Name Required Data Type Description
asp-action Optional String Used for the link's href. Same as the asp-action on a elements. If this is excluded it will be marked as the active item.
asp-controller Optional String Used for the link's href. Same as the asp-controller on a elements
asp-area Optional String Used for the link's href. Same as the asp-area on a elements
asp-route Optional RouteValues Used for the link's href. Same as the asp-route on a elements

breadcrumb-home

Creates a home breadcrumb. The all attributes are the same as breadcrumb but are all optional. Without any attributes the link to point to the HomeController, Index action, in the blank/root area. The default text is 'Home' unless something else is provided in the content of the tag helper.

Clone this wiki locally