---
title: "InsertLineBrakeCmd | Customer's Canvas On-Premises"
canonical: "https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms-text/InsertLineBrakeCmd/"
---

# InsertLineBrakeCmd

> The command to insert a line break relative to the current cursor position.

## Classes

### InsertLineBrakeCmd

#### Remarks

if there is selected text, it will be deleted.

#### Implements

- [`ICommand`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms-text/ICommand.md#icommand)

#### Constructors

##### Constructor

```ts
new InsertLineBrakeCmd(textManager, initData): InsertLineBrakeCmd;
```

###### Parameters

| Parameter | Type |
| ------ | ------ |
| `textManager` | [`ITextManager`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms-text/ITextManager.md#itextmanager) |
| `initData` | [`InsertLineBrakeCmdData`](#insertlinebrakecmddata) |

###### Returns

[`InsertLineBrakeCmd`](#insertlinebrakecmd)

#### Methods

##### execute()

```ts
execute(): boolean;
```

Executes the command.

###### Returns

`boolean`

true if changes were made, false otherwise.

###### Implementation of

[`ICommand`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms-text/ICommand.md#icommand).[`execute`](https://customerscanvas.com/docs/on-premises/design-atoms-js/reference/design-atoms-text/ICommand.md#execute)

***

### InsertLineBrakeCmdData

Data required to initialize the command.

#### Constructors

##### Constructor

```ts
new InsertLineBrakeCmdData(isNewLineEnabled): InsertLineBrakeCmdData;
```

###### Parameters

| Parameter | Type |
| ------ | ------ |
| `isNewLineEnabled` | `boolean` |

###### Returns

[`InsertLineBrakeCmdData`](#insertlinebrakecmddata)

#### Properties

##### isNewLineEnabled

```ts
isNewLineEnabled: boolean;
```

Indicates that new line insertion is enabled.
