---
id: fast-element.attachedbehaviorhtmldirective
title: AttachedBehaviorHTMLDirective class
hide_title: true
---
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[@microsoft/fast-element](./fast-element.md) &gt; [AttachedBehaviorHTMLDirective](./fast-element.attachedbehaviorhtmldirective.md)

## AttachedBehaviorHTMLDirective class

A directive that attaches special behavior to an element via a custom attribute.

<b>Signature:</b>

```typescript
export declare class AttachedBehaviorHTMLDirective<T = any> extends HTMLDirective 
```

## Constructors

|  Constructor | Modifiers | Description |
|  --- | --- | --- |
|  [(constructor)(name, behavior, options)](./fast-element.attachedbehaviorhtmldirective._constructor_.md) |  | Constructs a new instance of the <code>AttachedBehaviorHTMLDirective</code> class |

## Methods

|  Method | Modifiers | Description |
|  --- | --- | --- |
|  [createBehavior(target)](./fast-element.attachedbehaviorhtmldirective.createbehavior.md) |  | Creates a behavior for the provided target node. |
|  [createPlaceholder(index)](./fast-element.attachedbehaviorhtmldirective.createplaceholder.md) |  | Creates a placeholder string based on the directive's index within the template. |
