> ## Documentation Index
> Fetch the complete documentation index at: https://doc.lucidworks.com/llms.txt
> Use this file to discover all available pages before exploring further.

# search:breadcrumbs

export const LwTemplate = ({title = "Key questions to get you started", icon = "sparkles", cta = "Powered by Agent Studio", linkHref = "https://lucidworks.com/demo/?utm_source=docs&utm_medium=referral&utm_campaign=docs_cta_ai"}) => {
  const [isLoaded, setIsLoaded] = useState(false);
  useEffect(() => {
    const timer = setTimeout(() => {
      setIsLoaded(true);
    }, 500);
    return () => clearTimeout(timer);
  }, []);
  return <div className="lw-template-container">
      <Card title={title} icon={icon}>
        {isLoaded && <span dangerouslySetInnerHTML={{
    __html: `<lw-template id="a029c1a9-28be-427e-b0e1-5d918920246a"></lw-template
            >`
  }} />}
        <Link href={linkHref} className="agent-studio-link text-left text-gray-600 gap-2 dark:text-gray-400 text-sm font-medium flex flex-row items-center hover:text-primary dark:hover:text-primary-light group-hover:text-primary group-hover:dark:text-primary-light">Powered by Lucidworks Agent Studio</Link>
      </Card>
    </div>;
};

[localhost link]: http://localhost:3000/docs/4/app-studio/reference/tags/lightning.directive.searchBreadcrumbs

[mintlify link]: https://doc.lucidworks.com/docs/4/app-studio/reference/tags/lightning.directive.searchBreadcrumbs

[old doc.lw link]: https://doc.lucidworks.com/app-studio/4.2/1131

<LwTemplate />

## Description

The Breadcrumbs directive.

## Usage

as element:

```xml wrap  theme={"dark"}
<search:breadcrumbs
       [response="{object}"]
       [query="{string}"]
       [group-by-field="{boolean}"]
       [show-field-name="{boolean}"]
       [show-query="{boolean}"]
       [max-characters="{number}"]
       [action="{string}"]
       [optional-label="{string}"]
       [date-format="{string}"]
       [exclude="{string}"]>
</search:breadcrumbs>
```

### Directive info

* This directive creates new scope.

#### Parameters

| Param                         | Type        | Details                                                                                                                                       |
| ----------------------------- | ----------- | --------------------------------------------------------------------------------------------------------------------------------------------- |
| response  *(optional)*        | **object**  | A response object                                                                                                                             |
| query  *(optional)*           | **string**  | A query object                                                                                                                                |
| group-by-field  *(optional)*  | **boolean** | Group filters by field name (only available if query is not in grouping mode).                                                                |
| show-field-name  *(optional)* | **boolean** | Whether to show field name as a part of the breadcrumb (only available when group by field is true), Default:true.                            |
| show-query  *(optional)*      | **boolean** | Whether to include the user query text as a breadcrumb. Default:true                                                                          |
| max-characters  *(optional)*  | **number**  | Limit display value to a certain number of characters, adding ’…’ if maxCharacters is exceeded.                                               |
| action  *(optional)*          | **string**  | Alternative page to submit the query parameters to - defaults to current page.                                                                |
| optional-label  *(optional)*  | **string**  | Label to show when the Filter is optional.                                                                                                    |
| date-format  *(optional)*     | **string**  | Format to use for date values if no display value is specified. See #/api/lightning.filter:dateFormat\[date format filter] for valid formats. |
| exclude  *(optional)*         | **string**  | Comma separated list of fields to exclude, you can also use field=value to exclude only fields with the value provided.                       |

## Example

#### Source

```xml wrap  theme={"dark"}
<tk-example>
    <search:breadcrumbs response="response" group-by-field="true" date-format="shortDate" exclude="problem"></search:breadcrumbs>
</tk-example>
<tk-code-wrapper>
    <code hljs><search:breadcrumbs response="response" group-by-field="true" date-format="shortDate"></search:breadcrumbs></code>
</tk-code-wrapper>
```

```js wrap  expandable  theme={"dark"}
angular.module('lightning')
.controller('ExampleController', ['$scope','$timeout', function($scope,$timeout) {
            $scope.response = {
                page: 2,
                query: {
                    rpp: 50,
                    filters:[
                        {
                            field:'file type',
                            val:'pdf'
                        },
                        {
                            field:'type',
                            val:'man'
                        },
                        {
                            val:{
                                act: {
                                    type: "range",
                                    from: "2016-08-05T12:50:30.660",
                                    to: "2016-08-10T12:50:40.509",
                                    fromExcluded: false,
                                    toExcluded:false
                                },
                                dsp:'2016-08-05T12:50:30.660Z - 2016-08-10T12:50:40.509Z'
                            },
                            field:'date'
                        },
                        {
                            val: {
                                act: {
                                    type: "range",
                                    from: 100,
                                    to: "200",
                                    fromExcluded: false,
                                    toExcluded: false
                                },
                                dsp: '100 - 200'
                            },
                            field: 'numbers'
                        },
                        {
                            val: {
                                act:'foo',
                                dsp:'bar'
                            },
                            field:'problem'
                        }
                    ]
                },
                facets: {}
            }
        }]);
```

#### Result

<img src="https://mintcdn.com/lucidworks/ENcE8K39c0iEpL8J/assets/images/app-studio/as-examples/tags/searchBreadcrumbs.png?fit=max&auto=format&n=ENcE8K39c0iEpL8J&q=85&s=a84b72d9e70ba78318fddeb8a2fc52a4" alt="Result" width="1024" height="271" data-path="assets/images/app-studio/as-examples/tags/searchBreadcrumbs.png" />
