Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/vahidn/dntbreadcrumb.core

DNTBreadCrumb.Core Creates custom bread crumb definitions, based on Twitter Bootstrap features for ASP.NET Core applications.
https://github.com/vahidn/dntbreadcrumb.core

aspnetcore bootstrap breadcrumbs

Last synced: about 1 month ago
JSON representation

DNTBreadCrumb.Core Creates custom bread crumb definitions, based on Twitter Bootstrap features for ASP.NET Core applications.

Awesome Lists containing this project

README

        

# DNTBreadCrumb.Core



GitHub Actions status

`DNTBreadCrumb.Core` Creates custom bread crumb definitions, based on Twitter Bootstrap features for ASP.NET Core applications.

## Install via NuGet

[![Nuget](https://img.shields.io/nuget/v/DNTBreadCrumb.Core)](http://www.nuget.org/packages/DNTBreadCrumb.Core/)

To install DNTBreadCrumb.Core, run the following command in the Package Manager Console:

```
PM> Install-Package DNTBreadCrumb.Core
```

You can also view the [package page](http://www.nuget.org/packages/DNTBreadCrumb.Core/) on NuGet.

## Usage:

- After installing the DNTBreadCrumb.Core package, add the following definition to the [\_ViewImports.cshtml](/src/DNTBreadCrumb.Core.TestWebApp/Views/_ViewImports.cshtml) file:

```csharp
@addTagHelper *, DNTBreadCrumb.Core
```

- Then modify the [\_Layout.cshtml](/src/DNTBreadCrumb.Core.TestWebApp/Views/Shared/_Layout.cshtml) file to add its new tag-helper:

```xml

```

- Now you can add the `BreadCrumb` attributes to your controller or action methods:

```csharp
[BreadCrumb(Title = "Home", UseDefaultRouteUrl = true, Order = 0, IgnoreAjaxRequests = true)]
public class HomeController : Controller
{
[BreadCrumb(Title = "Main index", Order = 1, IgnoreAjaxRequests = true)]
public ActionResult Index()
{
return View();
}
```

Please follow the [TestWebApp](/src/DNTBreadCrumb.Core.TestWebApp), [TestWebApp.WithFeatureFolders](/src/DNTBreadCrumb.Core.TestWebApp.WithFeatureFolders) and [TestWebApp.WithRazorPages](/src/DNTBreadCrumb.Core.TestWebApp.WithRazorPages) samples for more scenarios.