GitHub

DaffCategoryBreadcrumb

import { DaffCategoryBreadcrumb } from '@daffodil/category'

A breadcrumb describing a traversal down a tree of categories, often found in an array describing the traversal to a particular category within a tree of categories.

interface DaffCategoryBreadcrumb {
  id: string
  name: string
  level: number
}

Properties

id
string

The id of the associated category.

name
string

A label to display the category name in the UI.

level
number

The number of nodes between this node and the root node for the category tree. For example, the level for a "Men's Shirts" breadcrumb could be 2 if the breadcrumb tree looked like: "Men" => "Clothing" => "Men's Shirts".