# Placeholder

> Defines placeholder text for a form-model property.

[API reference](/docs/api/index.md) › [Form Model](/docs/extensions/form-model/reference/index.md) › [Attribute](/docs/extensions/form-model/reference/attribute/index.md) › Placeholder

| final readonly class | `UIAwesome\FormModel\Attribute\Placeholder` |
| --- | --- |
| Source | [`src/Attribute/Placeholder.php`](https://github.com/ui-awesome/form-model/blob/main/src/Attribute/Placeholder.php#L18) |

Defines placeholder text for a form-model property.

Usage example:
```php
#[Placeholder('name@example.com')]
public string $email = '';
```

## Properties

| Property | Type | Description | Defined by |
| --- | --- | --- | --- |
| <span id="property-value"></span>`$value` readonly constructor | `string` | Placeholder text for the field. | `Placeholder` |

## Methods

| Method | Description | Defined by |
| --- | --- | --- |
| [`__construct()`](#method-__construct) | Creates field placeholder metadata. | `Placeholder` |

## Method details

### __construct() <span id="method-__construct"></span>

```php
public function __construct(string $value)
```

Creates field placeholder metadata.

**Parameters**

| Parameter | Type | Description |
| --- | --- | --- |
| `$value` | `string` | Placeholder text for the field. |