# UITextElementUpdate

***

The parameters for updating a text element.

See [UITextElement](https://developers.felt.com/js-sdk-api-reference/ui/uitextelement) for more details.

## Remarks

`id` and `type` are required to identify the element to update.

## Properties

### type

> **type**: `"Text"`

***

### id

> **id**: `string`

The ID of the element.

***

### content?

> `optional` **content**: `string`

The text to display in the element.

***

### onCreate()?

> `optional` **onCreate**: (`args`: { `id`: `string`; }) => `void`

A function to call when the element is created.

#### Parameters

| Parameter | Type                | Description                           |
| --------- | ------------------- | ------------------------------------- |
| `args`    | { `id`: `string`; } | The arguments passed to the function. |
| `args.id` | `string`            | The id of the element.                |

#### Returns

`void`

***

### onDestroy()?

> `optional` **onDestroy**: (`args`: { `id`: `string`; }) => `void`

A function to call when the element is destroyed.

#### Parameters

| Parameter | Type                | Description                           |
| --------- | ------------------- | ------------------------------------- |
| `args`    | { `id`: `string`; } | The arguments passed to the function. |
| `args.id` | `string`            | The id of the element.                |

#### Returns

`void`
